Browse Source

[minor-fix] Filtered the image files from other types of files

version-14
mbauskar 9 years ago
parent
commit
4184f6a3ce
1 changed files with 8 additions and 1 deletions
  1. +8
    -1
      frappe/public/js/frappe/list/imageview.js

+ 8
- 1
frappe/public/js/frappe/list/imageview.js View File

@@ -31,7 +31,14 @@ frappe.views.ImageView = Class.extend({
if(!r.message){
msgprint("No Images found")
} else{
me.render(r.message);
// filter image files from other
images = r.message.filter(function(image){
return frappe.utils.is_image_file(image.title);
});

if(images){
me.render(images);
}
}
}
});


Loading…
Cancel
Save