From b576573c980c13bddecea0860f86a903a0e37f99 Mon Sep 17 00:00:00 2001 From: Pedro Amorim Date: Mon, 30 Sep 2024 08:28:00 +0000 Subject: [PATCH] Bug 37856: Update atomicupdate messages (In reply to Katrin Fischer from comment #25) > The way the database update outputs messages is a bit non-standard. I fixed > the messages (we are not mentioning the bug number every time for example), > but I didn't change the structure. > I think what it should have done was printing different messages in case of > the column already existing or not, but the "Done" seems not quite right. > Not terribly important overall, just noting for future. (In reply to Jonathan Druart from comment #30) > 19 say_success( $out, "Done" ); > > Is this expected? "Done"? The original patch: https://github.com/Koha-Community/Koha/commit/2e4b1ca42f7a940e8329ed860dda102deb629db0#diff-661419b80761834f79ce9100a1f2a132b804ee7cdf4efffe14c29d93bec810e4R17 Had: say_success( $out, "Bug 37856 - Done" ); I wanted to provide indication that the update of that particular bug was done, regardless if a change on the database happened or not. This is clearly causing confusion, this is now showing messages more in line with standard I believe. --- installer/data/mysql/db_revs/240600032.pl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/installer/data/mysql/db_revs/240600032.pl b/installer/data/mysql/db_revs/240600032.pl index a2bbcd1007d..34e6d3dfeaf 100755 --- a/installer/data/mysql/db_revs/240600032.pl +++ b/installer/data/mysql/db_revs/240600032.pl @@ -14,8 +14,9 @@ return { ALTER TABLE erm_usage_data_providers ADD COLUMN `service_platform` varchar(80) DEFAULT NULL COMMENT 'platform if provider requires it' AFTER `report_types` } ); - say_info( $out, "Added column 'service_platformerm_usage_data_providers'" ); + say_success( $out, "Added column service_platform to table 'erm_usage_data_providers'" ); + } else { + say_info( $out, "Skipped adding column service_platform to table 'erm_usage_data_providers'. Column already exists." ); } - say_success( $out, "Done" ); }, }; -- 2.39.2