diff options
author | 2022-01-30 12:01:58 +0100 | |
---|---|---|
committer | 2022-01-30 12:01:58 +0100 | |
commit | 05a8f9a193b451cdf0333b16cf2d525e9d6eb8f4 (patch) | |
tree | ed03a6c721f8b829b6bf2ff656e1f60dccc41968 | |
parent | Redirects from old endpoints now filter correctly. (diff) |
Don't redirect if the resource_type is None!
-rw-r--r-- | pydis_site/static/js/resources.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/pydis_site/static/js/resources.js b/pydis_site/static/js/resources.js index bf570097..bfcd569d 100644 --- a/pydis_site/static/js/resources.js +++ b/pydis_site/static/js/resources.js @@ -113,7 +113,6 @@ function updateUI() { // Otherwise, hide everything and then filter the resources to decide what to show. let hasMatches = false; - console.log(hasMatches); resources.hide(); resources.filter(function() { let validation = { @@ -164,7 +163,7 @@ document.addEventListener("DOMContentLoaded", function () { like pydis.com/resources/communities. In this case, we'll rewrite the URL before we do anything else. */ let resourceTypeInput = $("#resource-type-input").val(); - if (resourceTypeInput.length !== 0) { + if (resourceTypeInput !== "None") { window.history.replaceState(null, document.title, `../?type=${resourceTypeInput}`); } |