mirror of
https://github.com/lrsjng/h5ai.git
synced 2025-05-31 15:28:19 -04:00
Fix file type check.
This commit is contained in:
parent
be827bac72
commit
99d59ee9ad
1 changed files with 1 additions and 1 deletions
|
@ -14,7 +14,7 @@ modulejs.define('core/types', ['config', '_'], function (config, _) {
|
|||
|
||||
_.each(types, function (patterns, type) {
|
||||
|
||||
var pattern = '^' + _.map(patterns, function (p) { return escapeRegExp(p).replace(/\*/g, '.*'); }).join('|') + '$';
|
||||
var pattern = '^(' + _.map(patterns, function (p) { return '(' + escapeRegExp(p).replace(/\*/g, '.*') + ')'; }).join('|') + ')$';
|
||||
regexps[type] = new RegExp(pattern, 'i');
|
||||
});
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue