Problem/Motivation
Navigating away from a node removes the lock but not the locked message.
Steps to reproduce:
1. Start editing a node to create a lock on that node.
2. Navigate away by clicking the "back" button.
3. Click the "leave page" button on the dialog that asks you if you want to leave the node you're editing.
4. Once back to the view of the node, click the browser refresh button
5. The node is locked message is displayed, even though the lock has been deleted.
6. Click refresh again, the message disapears.
Actual results:
After navigating away from a node being edited, the node is locked message is displayed once, even though the lock has been deleted.
Expected results:
You should never see the "Node is locked" message if the lock has already been deleted.
Proposed resolution
Anytime the a lock is deleted, any pending messages in $_SESSION['content_lock'] for that nid should also be deleted.
Remaining tasks
Apply attached patch.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | content_lock-remove_message-1450920-3.patch | 912 bytes | matason |
| content_lock-2-22-2012.patch | 814 bytes | jared_sprague |
Comments
Comment #1
aasarava commentedThis happens in 6.x-2.8 as well.
Comment #2
jaydub commentedComment #3
matason commentedThanks for the patch, it appears to work but it some circumstances it gives the following notice:
Notice: Undefined index: content_lock in content_lock_release() (line 548 of content_lock.module).
The attached patch against 7.x-1.x should fix this.
Comment #4
ohnobinki commentedI am unable to reproduce this at all in content_lock-6.x-2.8. May you detail how you managed to reproduce it including what browser you were using?
Comment #5
kmonty@jared_sprague - I was unable to reproduce this in 7.x-1.4 using your steps. Is this still a bug?
Comment #6
doublejosh commentedThis patch does fix the problem and is needed. However, it is not language aware and removes the locks for all nodes within the translation set whenever one is saved.
Scenario: open several edit pages for the same node's translations. Save the first translated node. Attempt to save another... lock has been deleted and the save action fails!
Comment #7
doublejosh commentedComment #8
pandaski commentedComment #9
astonvictor commentedI'm closing it because the issue was created a long time ago without any further steps.
if you still need it then raise a new one.
thanks