Last mimetype match fix fix, remove that trailing space.

This commit is contained in:
Nicolas Stepien 2012-01-03 22:19:22 +01:00
parent 439422d655
commit dcd14c9989
2 changed files with 2 additions and 2 deletions

View File

@ -1311,7 +1311,7 @@
} }
threads = "<select>" + threads + "</select>"; threads = "<select>" + threads + "</select>";
} }
mimeTypes = $('.rules').textContent.toLowerCase().match(/: (.+)/)[1].replace(/\w+/g, function(type) { mimeTypes = $('.rules').textContent.toLowerCase().match(/: (.+) /)[1].replace(/\w+/g, function(type) {
switch (type) { switch (type) {
case 'jpg': case 'jpg':
return 'image/jpeg'; return 'image/jpeg';

View File

@ -967,7 +967,7 @@ qr =
threads += "<option value=#{thread.id}>Thread #{thread.id}</option>" threads += "<option value=#{thread.id}>Thread #{thread.id}</option>"
threads = "<select>#{threads}</select>" threads = "<select>#{threads}</select>"
# chose only supported files # chose only supported files
mimeTypes = $('.rules').textContent.toLowerCase().match(/: (.+)/)[1].replace /\w+/g, (type) -> mimeTypes = $('.rules').textContent.toLowerCase().match(/: (.+) /)[1].replace /\w+/g, (type) ->
switch type switch type
when 'jpg' when 'jpg'
'image/jpeg' 'image/jpeg'