This commit is contained in:
Nicolas Stepien 2012-02-29 19:12:52 +01:00
parent 154cec7ee0
commit fe1991a68a
2 changed files with 6 additions and 4 deletions

View File

@ -664,8 +664,10 @@
return false; return false;
}, },
dimensions: function(root) { dimensions: function(root) {
var span; var match, span;
if (span = $('.filesize', root)) return span.textContent.match(/\d+x\d+/)[0]; if ((span = $('.filesize', root)) && (match = span.textContent.match(/\d+x\d+/))) {
return match[0];
}
return false; return false;
}, },
filesize: function(root) { filesize: function(root) {

View File

@ -574,8 +574,8 @@ filter =
return file.title return file.title
false false
dimensions: (root) -> dimensions: (root) ->
if span = $ '.filesize', root if (span = $ '.filesize', root) and match = span.textContent.match /\d+x\d+/
return span.textContent.match(/\d+x\d+/)[0] return match[0]
return false return false
filesize: (root) -> filesize: (root) ->
if img = $ 'img[md5]', root if img = $ 'img[md5]', root