Multiple fixes in imagefield
This commit is contained in:
parent
715979d08f
commit
ccb152ed07
1 changed files with 2 additions and 2 deletions
|
|
@ -121,7 +121,7 @@ class ImageField(CharField):
|
||||||
return ""
|
return ""
|
||||||
|
|
||||||
if 'minimum' in self.sizes:
|
if 'minimum' in self.sizes:
|
||||||
if self.sizes['minimum'][0]<real_width or self.sizes['minimum'][1]<real_height:
|
if self.sizes['minimum'][0]>real_width or self.sizes['minimum'][1]>real_height:
|
||||||
|
|
||||||
self.error=True
|
self.error=True
|
||||||
self.txt_error='Size is wrong. Minimum size is '+str(self.sizes['minimum'][0])+'x'+str(self.sizes['minimum'][1])
|
self.txt_error='Size is wrong. Minimum size is '+str(self.sizes['minimum'][0])+'x'+str(self.sizes['minimum'][1])
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue