[Koha-bugs] [Bug 21203] ILS-DI - GetRecords crashes on non-existent records

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon Aug 13 11:53:28 CEST 2018


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21203

Martin Renvoize <martin.renvoize at ptfs-europe.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|Needs Signoff               |Failed QA
                 CC|                            |martin.renvoize at ptfs-europe
                   |                            |.com

--- Comment #2 from Martin Renvoize <martin.renvoize at ptfs-europe.com> ---
QA Comment: Can we 100% guarantee that there is always 1 and only 1 biblioitem
attached to a biblio object?

Looking at the dbic schema it appears there's no db level constraint for this
(it's a has_many relationship), looking a level up in the Koha::Biblio object
it appears we do indeed fire a ->find rather than using the underlying dbic
relationship, which suggests there's only 1 (or 0) biblioitem attached to a
biblio but there's no test to confirm we actually get a biblioitem object back.

I'd love to see the underlying db constraints added, but would accept a second
check that the biblioitem exists before calling unblessed upon it.

Perhaps I'm being over cautious?

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list