I’ve successfully upgraded a EE 2.11.9 site to 3.5.16.
After upgrading to 4.3.1 I get a fatal error when I’m calling a parents relationship field in the template like:
{parents field="relationship_field"}
{parents:title} - {parents:field1} - {parents:field2}
{/parents}
The error is this:
Fatal error: Uncaught Error: Call to a member function getValues() on null in /path_to_hosting/public_html/new/system/ee/EllisLab/ExpressionEngine/Model/Channel/ChannelEntry.php:1156 Stack trace: #0 [internal function]: EllisLab\ExpressionEngine\Model\Channel\ChannelEntry->getModChannelResultsArray() #1 /path_to_hosting/public_html/new/system/ee/EllisLab/ExpressionEngine/Library/Data/Collection.php(85): call_user_func_array(Array, Array) #2 [internal function]: EllisLab\ExpressionEngine\Library\Data\Collection->EllisLab\ExpressionEngine\Library\Data\{closure}(Object(EllisLab\ExpressionEngine\Model\Channel\ChannelEntry)) #3 /path_to_hosting/public_html/new/system/ee/EllisLab/ExpressionEngine/Library/Data/Collection.php(244): array_map(Object(Closure), Array) #4 /path_to_hosting/public_html/new/system/ee/EllisLab/ExpressionEngine/Library/Data/Collection.php(93): EllisLab\ExpressionEngine\Library\Data\Collection->map(Object(Closure)) #5 /path_to_hosting/public_html/ne in /path_to_hosting/public_html/new/system/ee/EllisLab/ExpressionEngine/Model/Channel/ChannelEntry.php on line 1156
any ideas what could be wrong?
In case anyone runs across this issue - For me, it turned out that two of my parent entries were missing the ‘author_id’ in ‘exp_channel_titles’ table.
To see if this is your issue, using phpMyAdmin or run a SQL query to search where author_id = 0 from exp_channel_titles
May be related to this article
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.