Closed (fixed)
Project:
Invite
Version:
7.x-2.x-dev
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
8 Feb 2011 at 01:13 UTC
Updated:
12 Nov 2011 at 17:30 UTC
Jump to comment: Most recent file
After entering an email id and a message, then clicking on Invite button the below warning comes up along with the Fatal Error.
"Error
The website encountered an unexpected error. Please try again later.
Warning: unserialize() expects parameter 1 to be string, array given in invite_get_remaining_invites() (line 703 of /var/www/sites/all/modules/invite/invite.module).
Recoverable fatal error: Object of class stdClass could not be converted to string in DatabaseStatementBase->execute() (line 2039 of /var/www/includes/database/database.inc)."
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | invite-1054392.patch | 495 bytes | hadsie |
Comments
Comment #1
hadsie commentedComment #2
bnoice commentedSubscribe (from the dupe issue)
Comment #3
jacov commentedsubscribing
Comment #4
jacov commentedThe fix I believe is basically removing the unserialize function on line 698 of modules/invite/invite.module
Details, below...
Problem is here:
Fix is here:
Comment #5
sw3b commentedNice work thanks !
Comment #6
danielm commentedHello,
I put patch #4, When I go to the URL "http://www.yourdomain.com/invite" to invite a new friend, the following error message appeared:
Warning: unserialize() expects parameter 1 to be string, array given in invite_get_remaining_invites() (line 699 of /var/www/public/sites/all/modules/invite/invite.module).
This only appears when logged in as a normal registered user and not as the administrator (i.e. UID = 1).
Thank you for your help
Sincerely
Daniel
Comment #7
hadsie commentedHere's the fix rolled into a patch. Note that this patch is generated from a codebase that has already had the patches from #1124708: To the maintainers -- Can we get some D7 patches applied to code? applied.
Comment #8
glekli commentedCommitted. Also updated is the method the data is saved into the user object.
Thanks for the fix.