Skip to content

Commit

Permalink
Merge pull request #9 from w3c/sideshowbarker/handlerfix
Browse files Browse the repository at this point in the history
Fixed review miss from previous commit.
  • Loading branch information
jgraham committed Mar 5, 2014
2 parents 959fe6c + 1180b02 commit 0e284a1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions wptserve/handlers.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,10 @@ def get_headers(self, path):
return rv

def load_headers(self, path):
with open(path + ".headers") as headers_file:
return [tuple(item.strip() for item in line.split(":", 1))
for line in headers_file if line]
try:
with open(path + ".headers") as headers_file:
return [tuple(item.strip() for item in line.split(":", 1))
for line in headers_file if line]
except IOError:
return []

Expand Down

0 comments on commit 0e284a1

Please sign in to comment.