summaryrefslogtreecommitdiff
path: root/shared.pl
diff options
context:
space:
mode:
authorlshprung <lshprung@yahoo.com>2021-09-26 16:58:31 -0700
committerlshprung <lshprung@yahoo.com>2021-09-26 16:58:31 -0700
commit90c3eba635f31472ca4fb5ebec5910a41221dbbf (patch)
tree1556503403cccb82eeb4b8a89387e1161842618d /shared.pl
parentec07b105fed222b737ba2a69d380c3adb841e0cf (diff)
Added debug mode, fixed bug in checking for duplicate files
Diffstat (limited to 'shared.pl')
-rw-r--r--shared.pl4
1 files changed, 4 insertions, 0 deletions
diff --git a/shared.pl b/shared.pl
index 4c71855..b07071b 100644
--- a/shared.pl
+++ b/shared.pl
@@ -6,6 +6,10 @@
# @_[1] -> command/statement
# @_[2] (optional) -> output statement
sub db_cmd {
+ if ($options{debug}){
+ print "Preparing SQL query \"$_[1]\"\n"
+ }
+
my $sth = $_[0]->prepare($_[1]);
if ($sth->execute < 0){