Handle files with no diffs awkwardly, for now.
author |
Steve Losh <steve@stevelosh.com> |
date |
Wed, 03 Mar 2010 19:40:03 -0500 |
parents |
12301b2a5461
|
children |
bb734cf7e12c
|
branches/tags |
webpy-sucks |
files |
review/api.py |
Changes
--- a/review/api.py Wed Mar 03 19:34:12 2010 -0500
+++ b/review/api.py Wed Mar 03 19:40:03 2010 -0500
@@ -514,7 +514,10 @@
line_level_comments = self.line_level_comments(filename)
previous_n = -1
- yield content[-1][0]
+ if content:
+ yield content[-1][0]
+ else:
+ yield 0
for n, line in content:
if n - 1 > previous_n: