Skip to content

Commit

Permalink
Fix IOError when package.* file did not exist.
Browse files Browse the repository at this point in the history
Now flaggie should be able to create package.* files if they don't
exist.
  • Loading branch information
mgorny committed Nov 8, 2010
1 parent c80fd99 commit 00dfabd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/flaggie/packagefile.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,8 @@ def __init__(self, path):
self.path = path
# _modified is for when items are removed
self._modified = False
if not os.path.exists(path):
return
f = codecs.open(path, 'r', 'utf8')
for l in f:
try:
Expand Down

0 comments on commit 00dfabd

Please sign in to comment.