Side navigation
#9241 closed bug (duplicate)
Opened May 11, 2011 05:23PM UTC
Closed May 11, 2011 06:58PM UTC
Last modified May 11, 2011 06:58PM UTC
function dataAttr( elem, key, data ) @ line 1664 overwrites window.name
Reported by: | lasstlos@gmail.com | Owned by: | |
---|---|---|---|
Priority: | high | Milestone: | 1.6.1 |
Component: | data | Version: | 1.6 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Line 1664: name = "data-" + key.replace( rmultiDash, "$1-$2" ).toLowerCase();
The name variable is not declared so name scopes to window.name and overwrites the window.name variable. Adding a var to the beginning of this line resolves this issue. I believe line 1664 should be:
var name = "data-" + key.replace( rmultiDash, "$1-$2" ).toLowerCase();
How I came across this bug:
We currently use the window.name to hold a guid that is used to track the active window in a session. We then use this guid to prevent a user from getting multiple windows in the same session and getting an inconsistent session state. If window.name changes, we think that the browser window requesting the info is not the valid one and force the user to close their window.