# [PATCH] git-p4: Fix verbose printing

1 messages from 2016-06-22 to 2016-06-22. Participants: Ben Widawsky.
Thread: https://gitlist.dev/t/42686

## Ben Widawsky, 2016-06-22 05:10

Subject: [PATCH] git-p4: Fix verbose printing
Message-ID: <20160622051015.28946-1-ben@bwidawsk.net>
URL: https://gitlist.dev/e/20160622051015.28946-1-ben%40bwidawsk.net

```
The current logic seems to invert the error message when using verbose messages.
The inversion seems to be indicated by the caller:
if self.inClientSpec(f['path']) and self.hasBranchPrefix(f['path'])]

This behavior has existed since the original commit:
commit 4ae048e67e5f0d786b9febc438433d95f18e5937
Author: Lars Schneider <larsxschneider@gmail.com>
Date:   Tue Dec 8 10:36:22 2015 +0100

    git-p4: add option to keep empty commits

Note that there are no behavioral changes with this patch since the code did the
right thing, just with the wrong messages.

Cc: Lars Schneider <larsxschneider@gmail.com>
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
---
 git-p4.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/git-p4.py b/git-p4.py
index b6593cf..b123aa2 100755
--- a/git-p4.py
+++ b/git-p4.py
@@ -2674,7 +2674,7 @@ class P4Sync(Command, P4UserMap):
             return True
         hasPrefix = [p for p in self.branchPrefixes
                         if p4PathStartsWith(path, p)]
-        if hasPrefix and self.verbose:
+        if not hasPrefix and self.verbose:
             print('Ignoring file outside of prefix: {0}'.format(path))
         return hasPrefix
 
-- 
2.9.0


```
