Enable warnings in marctagstructure.pl
Fix a couple of comparisons generating warnings Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
This commit is contained in:
parent
f4b3c131dc
commit
eee07ae861
|
|
@ -19,6 +19,7 @@
|
|||
# Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
use CGI;
|
||||
use C4::Auth;
|
||||
use C4::Koha;
|
||||
|
|
@ -148,7 +149,7 @@ if ($op eq 'add_form') {
|
|||
my $repeatable = $input->param('repeatable') ? 1 : 0;
|
||||
my $mandatory = $input->param('mandatory') ? 1 : 0;
|
||||
my $authorised_value = $input->param('authorised_value');
|
||||
unless (C4::Context->config('demo') eq 1) {
|
||||
unless (C4::Context->config('demo') == 1) {
|
||||
if ($input->param('modif')) {
|
||||
$sth = $dbh->prepare(
|
||||
"UPDATE marc_tag_structure SET liblibrarian=? ,libopac=? ,repeatable=? ,mandatory=? ,authorised_value=? WHERE frameworkcode=? AND tagfield=?"
|
||||
|
|
@ -193,7 +194,7 @@ if ($op eq 'add_form') {
|
|||
################## DELETE_CONFIRMED ##################################
|
||||
# called by delete_confirm, used to effectively confirm deletion of data in DB
|
||||
} elsif ($op eq 'delete_confirmed') {
|
||||
unless (C4::Context->config('demo') eq 1) {
|
||||
unless (C4::Context->config('demo') == 1) {
|
||||
my $sth1 = $dbh->prepare("DELETE FROM marc_tag_structure WHERE tagfield=? AND frameworkcode=?");
|
||||
my $sth2 = $dbh->prepare("DELETE FROM marc_subfield_structure WHERE tagfield=? AND frameworkcode=?");
|
||||
$sth1->execute($searchfield, $frameworkcode);
|
||||
|
|
|
|||
Loading…
Reference in New Issue