]> git.koha-community.org Git - koha.git/commit
Bug 28221: Script process_message_queue.pl uses Try::Tiny but doesn't 'use' it
authorKyle M Hall <kyle@bywatersolutions.com>
Mon, 26 Apr 2021 10:30:17 +0000 (06:30 -0400)
committerAndrew Fuerste-Henry <andrew@bywatersolutions.com>
Mon, 24 May 2021 18:32:47 +0000 (18:32 +0000)
commitb62b66bddccdb441d494608ef69256476b03a06f
tree8d7417ca5ab5806851a6f3ea6e6b1a58150dd872
parent4f6716d96cce020e1b8166c2029188abe419aea8
Bug 28221: Script process_message_queue.pl uses Try::Tiny but doesn't 'use' it

The message queue processor has a try/catch block, but does not have a 'use Try::Tiny' line. Because of this the following error ocurrs if an instance has any plugins installed that use the before_send_messages hook:

Can't locate object method "catch" via package "1" (perhaps you forgot to load "1"?) at /usr/share/koha/bin/cronjobs/process_message_queue.pl line 86.

Test Plan:
1) Install a plugin that uses the before_send_messages hook
2) Run the message queue processor
3) Note the error message
4) Apply this patch
5) Run the message queue processor again
6) No error!

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 808d9a9f81a65921b70af92dba83d407e8e71caf)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 5a6afac654c2141829f7ab0ec44a4f5f4eaf1c43)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
misc/cronjobs/process_message_queue.pl