Skip to content

Commit

Permalink
fix(base.py): cast into a float more than an int percentage
Browse files Browse the repository at this point in the history
  • Loading branch information
Florentin Dubois committed Feb 20, 2018
1 parent ff380e5 commit 70df8a9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sauna/plugins/base.py
Expand Up @@ -63,9 +63,9 @@ def _value_to_status_more(cls, value, check_config, modifier=None):
@classmethod
def _strip_percent_sign(cls, value):
try:
return int(value)
return float(value)
except ValueError:
return int(value.split('%')[0])
return float(value.split('%')[0])

@classmethod
def _strip_percent_sign_from_check_config(cls, check_config):
Expand Down

0 comments on commit 70df8a9

Please sign in to comment.