From dd07b449687faebbff5882a85a412a0a4facde48 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Thu, 1 Jun 2023 11:35:15 -0300 Subject: [PATCH] Bug 22440: (QA follow-up) Fix wrong check in db_rev Signed-off-by: Tomas Cohen Arazi (cherry picked from commit a1924bb31d6106037c1e8dec2ea4b39f86235960) Signed-off-by: Matt Blenkinsop --- installer/data/mysql/db_revs/221105004.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/installer/data/mysql/db_revs/221105004.pl b/installer/data/mysql/db_revs/221105004.pl index 301508143b..0f5148b968 100755 --- a/installer/data/mysql/db_revs/221105004.pl +++ b/installer/data/mysql/db_revs/221105004.pl @@ -7,7 +7,7 @@ return { my ($args) = @_; my ($dbh, $out) = @$args{qw(dbh out)}; - if ( foreign_key_exists( 'illrequests', 'illrequests_bibfk' ) ) { + unless ( foreign_key_exists( 'illrequests', 'illrequests_bibfk' ) ) { $dbh->do(q{ ALTER TABLE illrequests ADD FOREIGN KEY illrequests_bibfk (`biblio_id`) REFERENCES `biblio` (`biblionumber`) ON DELETE SET NULL ON UPDATE CASCADE; -- 2.39.5