Skip to content

Commit

Permalink
Case-sensitive matching of "Location:" header
Browse files Browse the repository at this point in the history
cURL on High Sierra prints "location:", not "Location:"
  • Loading branch information
deanishe committed Sep 28, 2017
1 parent 385e840 commit 4ff900b
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 2 deletions.
Binary file not shown.
2 changes: 1 addition & 1 deletion src/info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ This workflow is released under the MIT License.</string>
</dict>
</dict>
<key>version</key>
<string>2.0.1</string>
<string>2.0.2</string>
<key>webaddress</key>
<string></string>
</dict>
Expand Down
2 changes: 1 addition & 1 deletion src/url_for_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def similar_images_url(image_path):
# Extract the `Location:` header
for line in output.split('\n'):
log('[response] %s', line)
if line.startswith('Location: '):
if line.lower().startswith('location: '):
redir_url = line[10:]
break

Expand Down

0 comments on commit 4ff900b

Please sign in to comment.