Hello,
I am experiencing the following bug. At the beginning I thought it was because of some weird hook I installed, but I debugged my code and I could not find any bug from my side. What I experience is the following:
When the Administrator user edits a comment, everything works fine. When an user (with permissions to do so) changes a comment that NOT belong to him, drupal changes authorship to him, instead of keeping the former creator. I put a print_r in comment_save, before drupal could perform any save onto the DB and this is what I got
stdClass Object
(
[cid] => 606
[pid] => 0
[nid] => 26762
[uid] => 97
[subject] => (Nessun oggetto)
[hostname] => x.x.x.x
[created] => 1450696779
[changed] => 1450696778
[status] => 1
[thread] => 04/
[name] => x
[mail] =>
[homepage] =>
[language] => und
[node_type] => comment_node_thread
[registered_name] => x
[u_uid] => 99
[signature] =>
[signature_format] => plain_text
As you can see, uid and u_uid DO NOT match. uid is the user id of the user (me in this case) that is changing comment id 606, whereas u_uid 99 is the former user.
Is anyone experiencing this issue? Is there a way to work this around?
Comments
Comment #2
TuTToWeB CreditAttribution: TuTToWeB commentedComment #3
N.kishorekumar CreditAttribution: N.kishorekumar commentedComment #4
N.kishorekumar CreditAttribution: N.kishorekumar as a volunteer and at Valuebound commentedTried to recreating the issue by
i)Authenticated user editing the other user comment
ii)admin editing the other user comment
In both the scenarios, it couldnt change the uid and u_uid(both are same), tried with blank drupal7 instance.
Comment #5
apadernoDefinitively, this is not the default behavior on Drupal. I could not reproduce it on a fresh Drupal 7 installation with the standard profile, and no third-party modules.