1

My task is to update all modules of a site and commit. Everything goes well except when I ran the command drush pm-update projects drupal-6.28

PHP Fatal error: Call-time pass-by-reference has been removed in /Users/scottnassery/c2d-deals2/sites/all/modules/contrib/uc_post_affiliate_pro/uc_post_affiliate_pro.module on line 926 Drush command terminated abnormally due to an unrecoverable error. [error] Error: Call-time pass-by-reference has been removed in /Users/scottnassery/c2d-deals2/sites/all/modules/contrib/uc_post_affiliate_pro/uc_post_affiliate_pro.module, line 926

Fatal error: Call-time pass-by-reference has been removed in /Users/scottnassery/c2d-deals2/sites/all/modules/contrib/uc_post_affiliate_pro/uc_post_affiliate_pro.module on line 926 Scotts-MacBook-Pro-2:c2d-deals2 scottnassery$ drush up uc_post_affiliate_pro --security-only --no-core PHP Fatal error: Call-time pass-by-reference has been removed in /Users/scottnassery/c2d-deals2/sites/all/modules/contrib/uc_post_affiliate_pro/uc_post_affiliate_pro.module on line 926 Drush command terminated abnormally due to an unrecoverable error. [error] Error: Call-time pass-by-reference has been removed in /Users/scottnassery/c2d-deals2/sites/all/modules/contrib/uc_post_affiliate_pro/uc_post_affiliate_pro.module,

My question is how can I fix that error and how can I restore the module to a old version should I redownload it and replace it?

2 Answers 2

2

Recently, Drush changed the default setting for recoverable errors to abort rather than continue when they are discovered. If this is causing problems, e.g. in an old module, then you can turn it off.

Create a file called drushrc.php, and place it in $HOME/.drush. Add the following contents:

<?php
$options['halt-on-error'] = FALSE;

You should then be able to continue without needing to fix the error in the non-compliant module.

2
0

This is actually a bug in Post Affiliate Pro module, which is trying to pass a variable by reference to a function on call time. You can simply fix this bug by updating uc_post_affiliate_pro.module file on the line 926:

uc_post_affiliate_pro_register_affiliate($edit, &$account);

into

uc_post_affiliate_pro_register_affiliate($edit, $account);

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.