]> git.koha-community.org Git - koha.git/commit
Bug 27714: Prevent Koha::NewsItem->author to explode
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Wed, 17 Feb 2021 11:03:56 +0000 (12:03 +0100)
committerFridolin Somers <fridolin.somers@biblibre.com>
Thu, 25 Feb 2021 09:38:46 +0000 (10:38 +0100)
commit2329f57f882fa493fb2943b3f242fbc6626ea61d
treea6b4c1d9a9aeb09b850c8bc41f7b079780acd2e4
parentabe0f0360cce1535a52bc5981cd1ac02397b816a
Bug 27714: Prevent Koha::NewsItem->author to explode

If the author of a news has been removed, Koha::NewsItem->author must
not explode

DBIC result _type  isn't of the _type Borrower at t/db_dependent/Koha/News.t line 68.

Test plan:
 prove t/db_dependent/Koha/News.t
must return green, and changes must be consistent

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 506b8f125b7c7dda1dc70b4963026ea975a8c655)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Koha/NewsItem.pm
t/db_dependent/Koha/News.t