-
Notifications
You must be signed in to change notification settings - Fork 180
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
891d721
commit eb54845
Showing
6 changed files
with
16 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
/** | ||
* cross-storage - Cross domain local storage | ||
* | ||
* @version 0.3.1 | ||
* @version 0.3.2 | ||
* @link https://github.com/zendesk/cross-storage | ||
* @author Daniel St. Jules <[email protected]> | ||
* @copyright Zendesk | ||
|
@@ -359,13 +359,19 @@ CrossStorageClient.prototype._request = function(method, params) { | |
|
||
// In case we have a broken Array.prototype.toJSON, e.g. because of | ||
// old versions of prototype | ||
var originalToJSON = Array.prototype.toJSON; | ||
Array.prototype.toJSON = null; | ||
var originalToJSON; | ||
|
||
if (Array.prototype.toJSON) { | ||
originalToJSON = Array.prototype.toJSON; | ||
Array.prototype.toJSON = null; | ||
} | ||
|
||
// Send serialized message | ||
client._hub.postMessage(JSON.stringify(req), client._origin); | ||
|
||
// Restore original toJSON | ||
Array.prototype.toJSON = originalToJSON; | ||
if (originalToJSON) { | ||
Array.prototype.toJSON = originalToJSON; | ||
} | ||
}); | ||
}; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
/** | ||
* cross-storage - Cross domain local storage | ||
* | ||
* @version 0.3.1 | ||
* @version 0.3.2 | ||
* @link https://github.com/zendesk/cross-storage | ||
* @author Daniel St. Jules <[email protected]> | ||
* @copyright Zendesk | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters