Skip to content

Commit

Permalink
set view mode on files like MP4, HTML...
Browse files Browse the repository at this point in the history
some filename extension is capital, need to .toLowerCase()
  • Loading branch information
iwestlin authored Mar 17, 2020
1 parent 9f5b55f commit f213d31
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion themes/material/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ function list_files(path,files){
});
}
var ext = p.split('.').pop();
if("|html|php|css|go|java|js|json|txt|sh|md|mp4|webm|avi|bmp|jpg|jpeg|png|gif|m4a|mp3|wav|ogg|mpg|mpeg|mkv|rm|rmvb|mov|wmv|asf|ts|flv|".indexOf(`|${ext}|`) >= 0){
if("|html|php|css|go|java|js|json|txt|sh|md|mp4|webm|avi|bmp|jpg|jpeg|png|gif|m4a|mp3|wav|ogg|mpg|mpeg|mkv|rm|rmvb|mov|wmv|asf|ts|flv|".indexOf(`|${ext.toLowerCase()}|`) >= 0){
p += "?a=view";
c += " view";
}
Expand Down

0 comments on commit f213d31

Please sign in to comment.