Skip to content

Commit

Permalink
Fixing error in index.py so it will run.
Browse files Browse the repository at this point in the history
There is an error when trying to run this code: TypeError: Unicode-objects must be encoded before hashing. I added the code to fix that issue.
  • Loading branch information
sho-luv authored and Kenneth Nielsen committed Jan 2, 2020
1 parent 612ae5a commit e23a162
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/webapp/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@


def gen_sig():
return hashlib.md5(
return hashlib.md5((
app.config['ROVI_API_KEY'] +
app.config['ROVI_SHARED_SECRET'] +
repr(int(time.time()))).hexdigest()
repr(int(time.time()))).encode('utf-8')).hexdigest()


def get_track_image(artist, album):
Expand Down

0 comments on commit e23a162

Please sign in to comment.