largefiles: cleanup of printmessage handling - the printed flag was redundant stable
authorMads Kiilerich <madski@unity3d.com>
Thu, 07 Nov 2013 01:47:59 +0100
branchstable
changeset 20060 750d04e747aa
parent 20057 d54467c1a198
child 20061 5cb0ff40374d
largefiles: cleanup of printmessage handling - the printed flag was redundant
hgext/largefiles/lfcommands.py
--- a/hgext/largefiles/lfcommands.py	Sat Nov 16 19:56:30 2013 -0500
+++ b/hgext/largefiles/lfcommands.py	Thu Nov 07 01:47:59 2013 +0100
@@ -438,10 +438,8 @@
         if filelist is not None:
             lfiles = [f for f in lfiles if f in filelist]
 
-        printed = False
         if printmessage and lfiles:
             ui.status(_('getting changed largefiles\n'))
-            printed = True
             cachelfiles(ui, repo, None, lfiles)
 
         updated, removed = 0, 0
@@ -452,12 +450,9 @@
                     updated += i
                 else:
                     removed -= i
-            if printmessage and (removed or updated) and not printed:
-                ui.status(_('getting changed largefiles\n'))
-                printed = True
 
         lfdirstate.write()
-        if printed and printmessage:
+        if printmessage and lfiles:
             ui.status(_('%d largefiles updated, %d removed\n') % (updated,
                 removed))
     finally: