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.
Error while submitting the unsubscribe form.
PDOException: SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'uid' cannot be null: INSERT INTO {unsubscribe} (uid, timestamp) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1); Array ( [:db_insert_placeholder_0] => [:db_insert_placeholder_1] => 1449042568 ) in unsubscribe_user_add() (line 386 of unsubscribe/unsubscribe.module).
Patch to fix this is attached.
Comment | File | Size | Author |
---|---|---|---|
#2 | 2627148-unsubscribe-undefined-mail.patch | 664 bytes | vaibhav571 |
Comments
Comment #2
vaibhav571 CreditAttribution: vaibhav571 as a volunteer commentedComment #3
Maedi CreditAttribution: Maedi commentedNo question about it, the line...
...must be in the function for the module to work.
+1 for this patch/adding in the line. It fixes an otherwise broken module.
Comment #4
oemb29 CreditAttribution: oemb29 commentedI added the line Worked but displays this issue:
Warning: array_flip(): Can only flip STRING and INTEGER values! in DrupalDefaultEntityController->load() (line 175 of /home/xx/public_html/x/includes/entity.inc).
Warning: array_flip(): Can only flip STRING and INTEGER values! in DrupalDefaultEntityController->cacheGet() (line 388 of /home/xx/public_html/x/includes/entity.inc).
Notice: Trying to get property of non-object in unsubscribe_user_check() (line 331 of /home/xx/public_html/x/sites/all/modules/unsubscribe/unsubscribe.module).