diff --git a/misc/cronjobs/anonymize_last_borrowers.pl b/misc/cronjobs/anonymize_last_borrowers.pl index 28de63a1f9..e0287fe075 100755 --- a/misc/cronjobs/anonymize_last_borrowers.pl +++ b/misc/cronjobs/anonymize_last_borrowers.pl @@ -36,6 +36,7 @@ use C4::Log; sub usage { print STDERR < \$help, 'v|verbose' => \$verbose, + 'c|confirm' => \$confirm, ) || usage(1); if ($help) { @@ -62,6 +64,12 @@ if ( !$pref ) { usage(1); } +unless ($confirm) { + print STDERR "You must use the --confirm flag to run this script.\n"; + print STDERR "Add --confirm to actually perform the anonymization.\n"; + exit(1); +} + cronlogaction(); my $rows = Koha::Patrons->anonymize_last_borrowers();