From e3455d2f3b100a13cbf7cfe6b36619096a2c4e8a Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sun, 24 Sep 2023 05:42:09 +0000 Subject: lei: check git-config(1) failures 2020-2021 were bad times and I somehow got deluded into believing git-config(1) would always succeed :x --- lib/PublicInbox/LeiForgetExternal.pm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lib/PublicInbox/LeiForgetExternal.pm') diff --git a/lib/PublicInbox/LeiForgetExternal.pm b/lib/PublicInbox/LeiForgetExternal.pm index 39bfc60b..c8d1df38 100644 --- a/lib/PublicInbox/LeiForgetExternal.pm +++ b/lib/PublicInbox/LeiForgetExternal.pm @@ -16,8 +16,7 @@ sub lei_forget_external { next if $seen{$l}++; my $key = "external.$l.boost"; delete($cfg->{$key}); - $lei->_config('--unset', $key); - if ($? == 0) { + if ($lei->_config('+e', '--unset', $key)) { $lei->qerr("# $l forgotten "); } elsif (($? >> 8) == 5) { warn("# $l not found\n"); -- cgit v1.2.3-24-ge0c7