aboutsummaryrefslogtreecommitdiff
path: root/sboremove
diff options
context:
space:
mode:
authorAndreas Guldstrand <andreas.guldstrand@gmail.com>2017-02-05 13:16:42 +0100
committerAndreas Guldstrand <andreas.guldstrand@gmail.com>2017-02-05 13:16:42 +0100
commit7d98bba95d59e3620f4cc9925d37cc57d435da9a (patch)
treeefa542bbae02ae76d74b160c41d6cc18136ac621 /sboremove
parentad087c56023d6429f2cb52986b3ddb16574517fe (diff)
downloadsbotools-7d98bba95d59e3620f4cc9925d37cc57d435da9a.tar.xz
sboremove: three more small fixes in logic
Diffstat (limited to 'sboremove')
-rwxr-xr-xsboremove6
1 files changed, 3 insertions, 3 deletions
diff --git a/sboremove b/sboremove
index 43a77c3..2a9be2b 100755
--- a/sboremove
+++ b/sboremove
@@ -168,9 +168,9 @@ sub confirm {
if ($remove->{warning}) {
say "It is recommended that you view the README before continuing.";
if (prompt("Display README now?", default => 'yes')) {
- my $readme = get_readme_contents(get_sbo_location($remove));
+ my $readme = get_readme_contents(get_sbo_location($remove->{name}));
if (not defined $readme) {
- warn "Unable to open README for $remove.\n";
+ warn "Unable to open README for $remove->{name}.\n";
} else {
print "\n" . $readme;
}
@@ -191,7 +191,7 @@ sub remove {
say sprintf "Removing %d package(s)", scalar @confirmed;
say join " ", map { $_->{name} } @confirmed;
- if (!$non_int and prompt("\nAre you sure you want to continue?", default => 'no')) {
+ if (!$non_int and !prompt("\nAre you sure you want to continue?", default => 'no')) {
return say 'Exiting.';
}