WordPress.org

Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #18515, comment 1


Ignore:
Timestamp:
08/25/11 07:53:32 (3 years ago)
Author:
azaozz
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #18515, comment 1

    initial v1  
    33We may need to delay adding the post lock as unload event is also triggered when the user reloads the page. That may result in race condition where the XHR removing the lock might arrive later than the new request for the page (that adds the lock). 
    44 
    5 Tested creating a function that adds the post lock and running it from the shutdown action after 2 sec delay (sleep 2). That may need a bit more thinking/testing. 
     5Tested creating a function that adds the post lock and running it from the shutdown action after 2 sec delay. Alternatively we can check the time the lock was added and not remove it if less than few sec. That may need a bit more thinking/testing.