After update of Features module to 2.7, we began getting PHP Fatal errors in consult module.

I am adding a patch to avoid execution of the failing method on string (not object).

Details of the error:

vagrant@webserver:/drupal/docroot$ drush fl
PHP Fatal error:  Call to a member function getSubEntitySetting() on string in /drupal/docroot/sites/all/modules/contrib/consult/includes/ConsultInterview.php on line 182
PHP Stack trace:
PHP   1. {main}() /usr/local/share/drush/drush.php:0
PHP   2. drush_main() /usr/local/share/drush/drush.php:16
PHP   3. _drush_bootstrap_and_dispatch() /usr/local/share/drush/drush.php:61
PHP   4. drush_dispatch() /usr/local/share/drush/drush.php:92
PHP   5. call_user_func_array:{/usr/local/share/drush/includes/command.inc:182}() /usr/local/share/drush/includes/command.inc:182
PHP   6. drush_command() /usr/local/share/drush/includes/command.inc:182
PHP   7. _drush_invoke_hooks() /usr/local/share/drush/includes/command.inc:214
PHP   8. call_user_func_array:{/usr/local/share/drush/includes/command.inc:362}() /usr/local/share/drush/includes/command.inc:362
PHP   9. drush_features_list() /usr/local/share/drush/includes/command.inc:362
PHP  10. features_get_storage() /drupal/docroot/sites/all/modules/contrib/features/features.drush.inc:217
PHP  11. features_get_component_states() /drupal/docroot/sites/all/modules/contrib/features/features.export.inc:660
PHP  12. features_get_signature() /drupal/docroot/sites/all/modules/contrib/features/features.export.inc:921
PHP  13. features_sanitize() /drupal/docroot/sites/all/modules/contrib/features/features.export.inc:684
PHP  14. features_remove_recursion() /drupal/docroot/sites/all/modules/contrib/features/features.export.inc:1012
PHP  15. unserialize() /drupal/docroot/sites/all/modules/contrib/features/features.export.inc:1107
PHP  16. Entity->__wakeup() /drupal/docroot/sites/all/modules/contrib/features/features.export.inc:1107
PHP  17. ConsultInterviewSubEntity->setUp() /drupal/docroot/sites/all/modules/contrib/entity/includes/entity.inc:328
Drush command terminated abnormally due to an unrecoverable error.                                                                                                                             [error]
Error: Call to a member function getSubEntitySetting() on string in /drupal/docroot/sites/all/modules/contrib/consult/includes/ConsultInterview.php, line 182

Comments

alex.skrypnyk’s picture

StatusFileSize
new1.13 KB

Attached is a re-rolled patch with checks for retrieved settings.