Skip to content

Commit

Permalink
[TOOLS-1515] use future basestring for cast
Browse files Browse the repository at this point in the history
  • Loading branch information
dwelch-spike committed Jun 25, 2020
1 parent 6bff8c8 commit eca019a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/utils/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
from builtins import str
from future.utils import raise_
from builtins import object
from past.builtins import basestring as future_basestring

import copy
import pipes
Expand Down Expand Up @@ -249,7 +250,7 @@ def _cast(value, return_type=None):


try:
if return_type == bool and isinstance(value, str):
if return_type == bool and isinstance(value, future_basestring):
if value.lower() == "false":
return False, True
if value.lower() == "true":
Expand Down

0 comments on commit eca019a

Please sign in to comment.