]> git.koha-community.org Git - koha.git/commit
Bug 23893: Special care for booleans
authorTomas Cohen Arazi <tomascohen@theke.io>
Wed, 15 Jan 2020 12:45:24 +0000 (09:45 -0300)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Wed, 15 Jan 2020 13:35:47 +0000 (13:35 +0000)
commit8b130c2eed52ba108752269470741c1321c67e96
tree3f4893d37b572b811879be55b4eec5dc25a6f823
parentfeb625ce50af6765498feb2ab15912e0286f48a9
Bug 23893: Special care for booleans

This patch acknowledges the fact that in D8 the Mojo::JSON->true and
Mojo::JSON->false values don't translate into integers when passed to
DBIC. It works correctly on D9 onwards, but we haven't formally
deprecated Jessie. This is adding back this translation, in the right
place now that all mappings code has been integrated into
Koha::Object(s) directly.

To test:
1. Apply this patch
2. Run:
   $ kshell
  k$ prove t/db_dependent/Koha/Object.t
=> SUCCESS: Tests pass!
3. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Koha/Object.pm
t/db_dependent/Koha/Object.t