projects
/
mw
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
fixing a bug when a page is blanked
[mw]
/
src
/
mw
/
clicommands.py
diff --git
a/src/mw/clicommands.py
b/src/mw/clicommands.py
index 4ecafb0d9aef17e6f2678021b3f2e18d2d0c52c0..6db3cb800f12c381d0eb539a2a92c4269923ada4 100644
(file)
--- a/
src/mw/clicommands.py
+++ b/
src/mw/clicommands.py
@@
-232,7
+232,7
@@
class CommitCommand(CommandBase):
filename = os.path.join(self.metadir.root, file)
text = codecs.open(filename, 'r', 'utf-8').read()
text = text.encode('utf-8')
- if
text[-1] == '\n'
:
+ if
(len(text) != 0) and (text[-1] == '\n')
:
text = text[:-1]
md5 = hashlib.md5()
md5.update(text)
Benjamin Mako Hill
||
Want to submit a patch?