Skip to content

Commit

Permalink
make admin redirect better
Browse files Browse the repository at this point in the history
  • Loading branch information
szabgab committed Oct 8, 2020
1 parent 1e3013b commit fafab94
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion static/admin.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,15 @@
localStorage.setItem(field, document.getElementById(field).checked);
}
var res = window.location.search.split("=");
window.location.href = res[1];
if (res[1] == undefined) {
if (window.location.hostname == "code-maven.com") {
window.location.href = "/slides";
} else {
// no idea where to go
}
} else {
window.location.href = res[1];
}
}

function start() {
Expand Down

0 comments on commit fafab94

Please sign in to comment.