diff --git a/src/assets/js/github.js b/src/assets/js/github.js index 4bbe273..2bdd747 100644 --- a/src/assets/js/github.js +++ b/src/assets/js/github.js @@ -57,7 +57,9 @@ function redirectIfQuery() { redirected = false; delimiterPosition = pageName.indexOf('#'); - if (delimiterPosition > 0) { + + // if a hashed query is passed and cant be matched with our list of valid topics, redirect a canned github search + if (pageName.length - 1 > delimiterPosition) { for (i=1; i < topicList.length; i++) { if (pageName.substr(delimiterPosition + 1) === topicList[i].innerHTML) { return redirected;