1
0
mirror of https://github.com/msberends/AMR.git synced 2026-03-05 18:17:23 +01:00
Files
AMR/R
Matthijs Berends 4e3ea95fbd Claude/fix issue 245 (#262)
* fix: restore valid AB codes mangled by generalise_antibiotic_name() (#245)

When as.ab() received a vector containing both valid AB codes (like ETH,
PHN, PHE, STH, THA, MTH, THI1) and an untranslatable value, the fast
path at line 100 was skipped. The slow path then applied
generalise_antibiotic_name(), which rewrites "TH"->"T" and "PH"->"F",
mangling these short AB codes (e.g. ETH->"ET", PHN->"FN") so they could
no longer be found in the lookup table.

Fix: save the pre-generalised values before applying
generalise_antibiotic_name(), then restore any elements that were already
valid AB codes in their original form.

https://claude.ai/code/session_01Sujw89qa48NoUmMPDBJLz9

* fix: use toupper() in AB code restoration to handle lowercase input (#245)

Ensures that lowercase user input (e.g. 'eth', 'phn') is matched
case-insensitively against the uppercase AB codes in $ab, and that
the restored value is stored in uppercase to match the lookup table.

https://claude.ai/code/session_01Sujw89qa48NoUmMPDBJLz9

* revert: remove unnecessary toupper() since x is already uppercased

https://claude.ai/code/session_01Sujw89qa48NoUmMPDBJLz9

* Revise versioning and date bump requirements for PRs

Updated versioning instructions for pull requests to include date bump.

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-03-04 08:59:44 +01:00
..
2025-04-29 16:15:18 +02:00
2026-01-16 10:57:03 +01:00
2025-04-12 11:46:42 +02:00
2026-01-08 14:03:02 +01:00
2026-03-04 08:59:44 +01:00
2025-04-12 11:46:42 +02:00
2026-01-16 10:57:03 +01:00
2025-04-12 11:46:42 +02:00
2026-01-06 23:08:50 +01:00
2026-01-16 10:57:03 +01:00
2025-04-12 11:46:42 +02:00
2025-06-02 12:11:00 +02:00
2025-04-12 11:46:42 +02:00
2025-04-12 11:46:42 +02:00
2025-07-19 14:06:36 +02:00
2025-06-01 15:35:04 +02:00
2025-04-12 11:46:42 +02:00
2025-04-12 11:46:42 +02:00
2025-04-12 11:46:42 +02:00
2025-09-20 17:14:07 +01:00
2025-06-13 16:12:28 +02:00
2025-04-12 11:46:42 +02:00
2026-01-08 10:21:48 +01:00
2025-04-12 11:46:42 +02:00
2025-06-01 12:17:47 +02:00