Koha-clms/Koha/OAI/Server
Tomas Cohen Arazi c8c8f08615 Bug 29484: Make ListSets return noSetHierarchy when no sets defined
This simple patch makes our OAI-PMH server return the appropriate error
code when no sets are defined.

To test:
1. Apply the regression tests
2. Run:
   $ kshell
  k$ t/db_dependent/OAI/Server.t
=> FAIL: Tests fail. Boo!
3. Apply this patch
4. Repeat 2
=> SUCCESS: Tests pass! YAY!
5. Sign off :-D

Bonus: you can check with the tool mentioned on the bug report, that
the error is gone. No sets need to be defined.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: David Nind <david@davidnind.com>

JD amended patch
-    ) unless scalar @{$sets} > 0;
+    ) unless @$sets;

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2021-12-10 21:14:59 -10:00
..
DeletedRecord.pm Bug 25898: Prohibit indirect object notation 2020-10-15 12:56:30 +02:00
Description.pm Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
GetRecord.pm Bug 29135: Fix handling of deleted items in OAI-PMH provider 2021-10-12 10:14:29 +02:00
Identify.pm Bug 21105: (QA follow-up) Avoid MySQL-ism 2021-11-15 12:38:39 +01:00
ListBase.pm Bug 29135: Fix handling of deleted items in OAI-PMH provider 2021-10-12 10:14:29 +02:00
ListIdentifiers.pm Bug 25898: Prohibit indirect object notation 2020-10-15 12:56:30 +02:00
ListMetadataFormats.pm Bug 15108: OAI-PMH provider improvements 2017-05-08 09:27:20 -04:00
ListRecords.pm Bug 25898: Prohibit indirect object notation 2020-10-15 12:56:30 +02:00
ListSets.pm Bug 29484: Make ListSets return noSetHierarchy when no sets defined 2021-12-10 21:14:59 -10:00
Record.pm Bug 25898: Prohibit indirect object notation 2020-10-15 12:56:30 +02:00
Repository.pm Bug 26195: Add a way to specify authorised values should be expanded [OAI] 2021-08-31 10:27:52 +02:00
ResumptionToken.pm Bug 28741: (follow-up) Silence warning 2021-08-04 09:14:46 +02:00