Bug 24064

Summary: DUEDGST typoed as DUEGST
Product: Koha Reporter: Magnus Enger <magnus>
Component: NoticesAssignee: Magnus Enger <magnus>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: major    
Priority: P5 - low CC: jonathan.druart, katrin.fischer, lucas, martin.renvoize
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
19.11.00
Bug Depends on: 20478    
Bug Blocks:    
Attachments: Bug 24064 - DUEDGST typoed as DUEGST
Bug 24064 - DUEDGST typoed as DUEGST
Bug 24064 - DUEDGST typoed as DUEGST

Description Magnus Enger 2019-11-19 10:12:49 UTC
Attachment 86382 [details] of bug introduces a typo in the letter code DUEDGST:

-    my $letter_type = 'DUEDGST';
+    letter_code => 'DUEGST',

This causes "Item Due Reminder (Digest)" messages not to be sent.
Comment 1 Magnus Enger 2019-11-19 10:13:37 UTC
Hm, that should be bug 20478.
Comment 2 Katrin Fischer 2019-11-19 10:16:48 UTC
But 20478 is not in 18.11?
Comment 3 Magnus Enger 2019-11-19 10:22:08 UTC
Created attachment 95532 [details] [review]
Bug 24064 - DUEDGST typoed as DUEGST

Bug 20478 introduced a typo where the letter code DUEDGST was changed
to DUEGST. This patch fixes it.

To test:
- Run "grep -r DUEDGST *" on the Koha git repo. Notice that this letter
  code is used in e.g. sample notices.
- Run "grep -r DUEGST *" and notice that this code only occurs twice,
  in misc/cronjobs/advance_notices.pl.
- Aply this patch.
- Run "grep -r DUEGST *" again, and notice there are no more occurences
  of this typo.
Comment 4 Magnus Enger 2019-11-19 10:32:08 UTC
(In reply to Katrin Fischer from comment #2)
> But 20478 is not in 18.11?

No, Martin wrote: "Enhancement will not be backported to 18.11.x series." How so?
Comment 5 Magnus Enger 2019-11-19 10:33:15 UTC
Ah, the version was set to 18.11? Dunno how that happened... Set it to master now.
Comment 6 David Nind 2019-11-19 10:51:52 UTC
Created attachment 95539 [details] [review]
Bug 24064 - DUEDGST typoed as DUEGST

Bug 20478 introduced a typo where the letter code DUEDGST was changed
to DUEGST. This patch fixes it.

To test:
- Run "grep -r DUEDGST *" on the Koha git repo. Notice that this letter
  code is used in e.g. sample notices.
- Run "grep -r DUEGST *" and notice that this code only occurs twice,
  in misc/cronjobs/advance_notices.pl.
- Aply this patch.
- Run "grep -r DUEGST *" again, and notice there are no more occurences
  of this typo.

Signed-off-by: David Nind <david@davidnind.com>
Comment 7 Jonathan Druart 2019-11-19 10:56:52 UTC
Caused by
  commit e18626b6f142128064317e95ef4a7fb089f4f48d
  Bug 20478: Refactor to remove code duplication.
Comment 8 Jonathan Druart 2019-11-19 11:09:55 UTC
That sucks!
What about the notices in the DB? :-/
Comment 9 Magnus Enger 2019-11-19 12:46:23 UTC
(In reply to Jonathan Druart from comment #8)
> What about the notices in the DB? :-/

letters or message_queue? None of them should be affected, except that since DUEGST is not found in letters, no DUE(D)GST messages will end up in message_queue.
Comment 10 Jonathan Druart 2019-11-19 13:13:58 UTC
Created attachment 95547 [details] [review]
Bug 24064 - DUEDGST typoed as DUEGST

Bug 20478 introduced a typo where the letter code DUEDGST was changed
to DUEGST. This patch fixes it.

To test:
- Run "grep -r DUEDGST *" on the Koha git repo. Notice that this letter
  code is used in e.g. sample notices.
- Run "grep -r DUEGST *" and notice that this code only occurs twice,
  in misc/cronjobs/advance_notices.pl.
- Aply this patch.
- Run "grep -r DUEGST *" again, and notice there are no more occurences
  of this typo.

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 11 Martin Renvoize 2019-11-19 15:16:02 UTC
Nice work!

Pushed to master for 19.11.00
Comment 12 Lucas Gass 2019-12-16 21:32:57 UTC
backported to 19.05.x for 19.05.06