Skip to content

Commit

Permalink
Merge pull request #782 from eaguad1337/fix/linter
Browse files Browse the repository at this point in the history
fix linter
  • Loading branch information
josephmancuso authored Feb 12, 2024
2 parents ffc445c + 0d68bb7 commit da7f7f7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/masonite/essentials/helpers/hashid.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

def hashid(*values, decode=False, min_length=7):
hash_class = Hashids(min_length=min_length)
if type(values[0]) == dict and decode:
if isinstance(values[0], dict) and decode:
new_dict = {}
for key, value in values[0].items():
if hasattr(value, "value"):
Expand All @@ -12,7 +12,7 @@ def hashid(*values, decode=False, min_length=7):
if value and hash_class.decode(value):
value = hash_class.decode(value)

if type(value) == tuple:
if isinstance(value, tuple):
value = value[0]
new_dict.update({key: value})
return new_dict
Expand Down

0 comments on commit da7f7f7

Please sign in to comment.