Switch to unified view
a/Allura/allura/model/filesystem.py | b/Allura/allura/model/filesystem.py | ||
---|---|---|---|
... |
... |
||
161 | original = None |
161 | original = None |
162 | 162 | ||
163 | thumbnail = cls.save_thumbnail(filename, image, content_type, thumbnail_size, thumbnail_meta, square) |
163 | thumbnail = cls.save_thumbnail(filename, image, content_type, thumbnail_size, thumbnail_meta, square) |
164 | 164 | ||
165 | return original, thumbnail |
165 | return original, thumbnail |
166 | 166 | ||
167 | def is_image(self): |
167 | def is_image(self): |
168 | return (self.content_type |
168 | return (self.content_type |
169 | and self.content_type.lower() in SUPPORTED_BY_PIL) |
169 | and self.content_type.lower() in SUPPORTED_BY_PIL) |
170 | 170 | ||
171 | @property |
||
172 | def length(self): |
||
173 | return self.rfile().length |