Created
January 16, 2014 11:09
-
-
Save warpech/8453185 to your computer and use it in GitHub Desktop.
Better error message for replaced session in PuppetJS
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
Puppet.prototype.setReferer = function (referer) { | |
if(this.referer && this.referer !== referer) { | |
this.showError("Error: Session lost", "Server replied with a different session ID that was already set. \nPossibly a server restart happened while you were working. \nPlease reload the page.\n\nPrevious session ID: " + this.referer + "\nNew session ID: " + referer); | |
} | |
this.referer = referer; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment