Closed (fixed)
Project:
Comment edited
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
29 Aug 2010 at 18:55 UTC
Updated:
26 Sep 2010 at 06:50 UTC
After the last patch from this thread #878914: Comment moderated by poster? hidden edits are now gone.
I guess it's this line that is removed:
$data->type = user_access('make hidden edit') ? COMMENT_HIDDEN_EDIT : COMMENT_STANDARD_EDIT;
Comments
Comment #1
snufkin commentedPlease define "gone".
Comment #2
magnus commentedI have a role that have the permission to make hidden edits. The permission is still there, but when a user with that role now makes an edit of a comment, then the edit is not hidden any longer as it was before #878914: Comment moderated by poster?.
I tried both with and without the permission "show hidden edits" and the hidden edit still shows for all users regardless of role (as long as they have the permission to view an edit message).
Comment #3
snufkin commentedIs that any comment, or just comments made by that user?
Comment #4
magnus commentedThis is any comment, not just that user.
Comment #5
magnus commentedUnfortunately, I misunderstood your question. The hidden edits do work if a user with the permission to do a hidden edit makes an edit on another users comment. But if the user edits his own comment, then the edit isn't hidden.
Comment #6
snufkin commentedHmm then its a clash with the issue quoted above :( I think then we should move it to a setting, to make that feature optional, and revert to the old behaviour by default.
Comment #7
snufkin commentedI committed a change to achieve this, please test the dev once it is updated.
Comment #8
magnus commentedI tried out the new dev and checked "Editing own comment is regular edit" on and off, but with the same result as before. The edit message still shows up.
Just for trial and error I tried to change the code:
'#default_value' => variable_get('comment_edited_own_edit_hidden', 0),to
'#default_value' => variable_get('comment_edited_own_edit_hidden', 1),but still same result, independently of the setting mentioned above.
Comment #9
snufkin commentedDid you also try to make a new edit? Im afraid this setting wont make an existing edit appear as hidden, it will only apply to new edits.
Comment #10
magnus commentedYes, I tried it on new comments.
Comment #11
snufkin commentedCommitted a new fix, this worked for me. I changed the variable name to reflect the setting it means, also fixed the duplicate entry error by adding the type as the second key to the drupal_write_record call.
Comment #12
magnus commentedThanks a lot! Now the different settings works as supposed.
Comment #13
snufkin commentedCool, i'll roll a new stable release then, because this is a bug, so it should go out asap.