[StGit BUG/PATCH] config.py: fix unset

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Chris Packham <judge.packham@xxxxxxxxx>

Missing invocation of .run() so config.unset('blah') didn't do anything.
Consequently the fact that the next line set the value to 'None' instead of a
list with 1 element i.e. '[None]' was not noticed.

Signed-off-by: Chris Packham <judge.packham@xxxxxxxxx>
---
 stgit/config.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/stgit/config.py b/stgit/config.py
index 4a6cb3b..6f84b10 100644
--- a/stgit/config.py
+++ b/stgit/config.py
@@ -94,8 +94,8 @@ class GitConfig:
        self.__cache[name] = value

    def unset(self, name):
-        Run('git', 'config', '--unset', name)
-        self.__cache[name] = None
+        Run('git', 'config', '--unset', name).run()
+        self.__cache[name] = [None]

    def sections_matching(self, regexp):
        """Takes a regexp with a single group, matches it against all
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]