Skip to content

Instantly share code, notes, and snippets.

@BombekeQuinten
Created April 23, 2019 05:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BombekeQuinten/3efd3fd40527faab429284981d8fae8c to your computer and use it in GitHub Desktop.
Save BombekeQuinten/3efd3fd40527faab429284981d8fae8c to your computer and use it in GitHub Desktop.
function isValid(url) {
return /^http(s)?:\/\/[0-9a-z.-]+\.security.com$/gi.test(url);
}
var url = window.location.hash.substr(1);
if (isValid(url)) {
window.location = url;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment