Show More
@@ -360,18 +360,6 b' class DiffProcessor(object):' | |||
|
360 | 360 | stats = None |
|
361 | 361 | msgs = [] |
|
362 | 362 | |
|
363 | if not head['a_file'] and head['b_file']: | |
|
364 | op = 'A' | |
|
365 | stats = ['b', NEW_FILENODE] | |
|
366 | msgs.append('new file') | |
|
367 | elif head['a_file'] and head['b_file']: | |
|
368 | op = 'M' | |
|
369 | stats = ['b', MOD_FILENODE] | |
|
370 | elif head['a_file'] and not head['b_file']: | |
|
371 | op = 'D' | |
|
372 | stats = ['b', DEL_FILENODE] | |
|
373 | msgs.append('deleted file') | |
|
374 | else: | |
|
375 | 363 |
|
|
376 | 364 |
|
|
377 | 365 |
|
@@ -392,6 +380,15 b' class DiffProcessor(object):' | |||
|
392 | 380 |
|
|
393 | 381 |
|
|
394 | 382 |
|
|
383 | if op is None: # fall back: detect missed old style add or remove | |
|
384 | if not head['a_file'] and head['b_file']: | |
|
385 | op = 'A' | |
|
386 | stats = ['b', NEW_FILENODE] | |
|
387 | msgs.append('new file') | |
|
388 | elif head['a_file'] and not head['b_file']: | |
|
389 | op = 'D' | |
|
390 | stats = ['b', DEL_FILENODE] | |
|
391 | msgs.append('deleted file') | |
|
395 | 392 |
|
|
396 | 393 |
|
|
397 | 394 |
|
General Comments 0
You need to be logged in to leave comments.
Login now