Vandelay authority existing queue search repair
authorBill Erickson <berick@esilibrary.com>
Wed, 16 May 2012 19:55:23 +0000 (15:55 -0400)
committerLebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Thu, 17 May 2012 13:51:41 +0000 (09:51 -0400)
When searching for an existing authority queue, search for an authority
queue, not a bib queue.  Apart from simply not working, the query will
fail with an "invalid input value for enum vandelay.bib_queue_queue_type"
and result in a client-side error.

https://bugs.launchpad.net/evergreen/+bug/989391

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Open-ILS/src/perlmods/lib/OpenILS/Application/Vandelay.pm

index 5c06e96..89a7d8d 100644 (file)
@@ -110,7 +110,7 @@ sub create_auth_queue {
     return $e->die_event unless $e->allowed('CREATE_AUTHORITY_IMPORT_QUEUE');
     $owner ||= $e->requestor->id;
 
-    if ($e->search_vandelay_bib_queue({name => $name, owner => $owner, queue_type => $type})->[0]) {
+    if ($e->search_vandelay_authority_queue({name => $name, owner => $owner, queue_type => $type})->[0]) {
         $e->rollback;
         return OpenILS::Event->new('AUTH_QUEUE_EXISTS') 
     }