Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Log: Recoverable fatal error: Method DatabaseCondition::__toString() must return a string value in privatemsg_realname_query_privatemsg_autocomplete_alter() (line 60 of sites/all/modules/privatemsg/privatemsg_realname/privatemsg_realname.module).
That cause AJAX error on Autocomplete Username when writing a new private message on IE or Chrome (Firefox is OK) in
function privatemsg_realname_query_privatemsg_autocomplete_alter(SelectQueryInterface $query) {}
if ($condition['field'] == 'u.name') {
should be change to
if (isset($condition['field']) && is_string($condition['field'])
&& $condition['field'] == 'u.name') {
to fix this Error.
Comment | File | Size | Author |
---|---|---|---|
#3 | privatemsg-ajax-autocomplete-error-1956038-3.patch | 801 bytes | ptmkenny |
Comments
Comment #1
Johann Wagner CreditAttribution: Johann Wagner commentedI got this bug on Firefox too.
Thank you.
Comment #2
ptmkenny CreditAttribution: ptmkenny commentedMarking http://drupal.org/node/1911138 as duplicate although there is another workaround suggested there.
Comment #3
ptmkenny CreditAttribution: ptmkenny commentedAttaching a patch. All credit goes to memberall.
Comment #5
ptmkenny CreditAttribution: ptmkenny commented#3: privatemsg-ajax-autocomplete-error-1956038-3.patch queued for re-testing.
Comment #7
ptmkenny CreditAttribution: ptmkenny commentedComment #8
ptmkenny CreditAttribution: ptmkenny commented#3: privatemsg-ajax-autocomplete-error-1956038-3.patch queued for re-testing.
Comment #9
ptmkenny CreditAttribution: ptmkenny commentedThere's a comment here: https://drupal.org/node/1911138#comment-7502500 that states this patch fixes the problem in IE.
Comment #10
ptmkenny CreditAttribution: ptmkenny commentedMarked https://drupal.org/node/2007058 as a duplicate, although there is another patch there to fix this issue.
Comment #11
BerdirCommitted and pushed.