[Koha-bugs] [Bug 31080] Block adding the bundle item to its own bundle
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Fri Nov 18 11:25:47 CET 2022
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31080
--- Comment #15 from Marcel de Rooy <m.de.rooy at rijksmuseum.nl> ---
if ( ref($_) eq 'Koha::Exceptions::Object::DuplicateID' ) {
return $c->render(
status => 409,
openapi => {
error => 'Item is already bundled',
key => $_->duplicate_id
}
);
}
elsif ( ref($_) eq 'Koha::Exceptions::Item::Bundle::IsBundle' ) {
return $c->render(
status => 400,
openapi => {
error => 'Bundles cannot be nested'
Somehow I wonder why we differentiate here between 400 and 409 ? 400 is the
general failure, 409 is a conflict. The nested bundle could be a 409 too. But I
would not mind having both on 400 as well. This seems inconsistent.
No blocker, easily to be adjusted..
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list