diff options
| author | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-05-15 08:07:37 +0200 | 
|---|---|---|
| committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-05-15 08:07:37 +0200 | 
| commit | 4e1d107f3cb668375669e1efb93065ad77b61786 (patch) | |
| tree | a79877483d426915998952766693d23faf4e67f7 /ishtar_common/forms.py | |
| parent | 56eafa6839505329e3adef1055ac729e8310681a (diff) | |
| download | Ishtar-4e1d107f3cb668375669e1efb93065ad77b61786.tar.bz2 Ishtar-4e1d107f3cb668375669e1efb93065ad77b61786.zip  | |
Float field: fix clean with native float
Diffstat (limited to 'ishtar_common/forms.py')
| -rw-r--r-- | ishtar_common/forms.py | 2 | 
1 files changed, 1 insertions, 1 deletions
diff --git a/ishtar_common/forms.py b/ishtar_common/forms.py index ecae18c5e..7eb36f6cc 100644 --- a/ishtar_common/forms.py +++ b/ishtar_common/forms.py @@ -80,7 +80,7 @@ class FloatField(forms.FloatField):      Allow the use of comma for separating float fields      """      def clean(self, value): -        if value: +        if value and (isinstance(value, unicode) or isinstance(value, str)):              value = value.replace(',', '.').replace('%', '')          return super(FloatField, self).clean(value)  | 
