Skip to content

Commit

Permalink
fix: 修复无后缀文件
Browse files Browse the repository at this point in the history
  • Loading branch information
vcheckzen committed Sep 20, 2024
1 parent c4f341e commit 7432522
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions front-end/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1190,9 +1190,12 @@
},
};

const suffix = path.split('.').pop();
let content = document.querySelector('.content');
const name = path.split('/').pop();
const suffix = name.includes('.')
? name.split('.').pop()
: '__no_suffix__';

let content = document.querySelector('.content');
content.appendChild(
document
.getElementById('loading-wrapper-templete')
Expand Down

0 comments on commit 7432522

Please sign in to comment.