Fixed nonexistent level comments not loading

This commit is contained in:
GDColon 2021-12-23 23:55:20 -05:00
parent b8201569ca
commit f53b4790a2

View file

@ -160,7 +160,9 @@ function clean(text) {return text.replace(/&/g, "&#38;").replace(/</g, "&#60;").
$('#compactMode').attr('src', `../assets/compact-${compact ? "on" : "off"}.png`)
Fetch(target).then(lvl => {
Fetch(target).then(lvl => buildComments(lvl)).catch(e => buildComments({}))
function buildComments(lvl) {
if (gdps) {
$('#leaveComment').hide()
@ -533,7 +535,7 @@ $(document).keydown(function(k) {
}
});
});
};
</script>