warning after enabling this module - Call-time pass-by-reference has been deprecated
igorik - August 21, 2007 - 13:14
| Project: | Fuzzy Search |
| Version: | 5.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | critical |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
Hi, after I enable this module, I got this warning message on each page:
Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of module_invoke_all(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /home/somvprahe.sk/somvprahe.sk/www/sites/all/modules/fuzzysearch/fuzzysearch.module on line 297
Igor
somvprahe.sk

#1
This was caused by a call to invoking all modules with a preprocess hook that allows them to filter out words from the index before the node is indexed. I have removed this line in the latest dev snapshot and will look for a better way to implement it in the future versions.
Thanks for the report.
#2
I've just installed the dev version of today and I got the same PHP warning
#3
The dev version as of sept 1st does not have this error, nor should the last version have. I'm not sure what is going on, but I just redownloaded it and the line you noted the error on is a comment. You may want to try re-downloading the latest dev snapshot, I'm certain its all working as I tried it myself today on 3 different installations just to make sure all the install issues were handled.
If it still doesn't work please do follow up and I will try to debug it further.
Thanks,
Blake
#4
Hi,
I just installed both available versions (first 1.2, then the dev-version) and got the same error. In my case, Drupal complaints about another line in the module's code (319).
Here's the warning message:
Warning: Call-time pass-by-reference has been deprecated; If you would like to pass it by reference, modify the declaration of module_invoke_all(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. in /is/htdocs/wp1047547_E9BWYAUVHP/www/subdomain/sites/all/modules/fuzzysearch/fuzzysearch.module on line 319Thanks.
#5
I can confirm this. Same version of the module and same error message.
#6
same issue here
#7
Well, has the author given up?
#8
That would be a shame, but it seems to be the case.
For what its worth: disabling lines 318, 319 & 320 in fuzzysearch.module gets rid of the error, though I haven't tested for any side effects:
<?php318 # if (variable_get('search_stop_words', false)) {
319 # module_invoke_all('search_filter', &$text);
320 # }
?>
#9
Yep, confirmed here too.
#10
You dont need to remove that entire line of code - just remove the pass-by-reference like so
// Strip all stop words if stop words are enabledif (variable_get('search_stop_words', false)) {
module_invoke_all('search_filter', $text);
}