@@ -1,6 +1,7 @@
|
||||
unreleased
|
||||
==========
|
||||
|
||||
* Fix icons for MIME types with `+`
|
||||
* Fix text and json responses to match html sorting
|
||||
* Show font icon for more font types
|
||||
* Use 400 error on URI decode failure instead of 500
|
||||
|
||||
2
index.js
2
index.js
@@ -416,7 +416,7 @@ function iconLookup(filename) {
|
||||
// try by mime type
|
||||
if (icons[mimetype]) {
|
||||
return {
|
||||
className: 'icon-' + mimetype.replace('/', '-'),
|
||||
className: 'icon-' + mimetype.replace('/', '-').replace('+', '_'),
|
||||
fileName: icons[mimetype]
|
||||
};
|
||||
}
|
||||
|
||||
0
test/fixtures/collect/sample.svg
vendored
Normal file
0
test/fixtures/collect/sample.svg
vendored
Normal file
@@ -386,6 +386,7 @@ describe('serveIndex(root)', function () {
|
||||
.expect(/icon-default/)
|
||||
.expect(/icon-directory/)
|
||||
.expect(/icon-image/)
|
||||
.expect(/icon-image-svg_xml/)
|
||||
.expect(/icon-txt/)
|
||||
.expect(/icon-application-pdf/)
|
||||
.expect(/icon-video/)
|
||||
|
||||
Reference in New Issue
Block a user