LP1983991 handle when IN list empty
authorLlewellyn Marshall <llewellyn.marshall@ncdcr.gov>
Tue, 25 Oct 2022 14:11:14 +0000 (10:11 -0400)
committerJane Sandberg <js7389@princeton.edu>
Fri, 28 Oct 2022 04:54:41 +0000 (21:54 -0700)
Signed-off-by: Jane Sandberg <js7389@princeton.edu>
Open-ILS/web/js/ui/default/staff/circ/services/circ.js

index a73cae2..a06e167 100644 (file)
@@ -721,6 +721,7 @@ function($uibModal , $q , egCore , egAlertDialog , egConfirmDialog,  egAddCopyAl
             var addr_id = org[addr_type](); 
             if(addr_id)addr_ids.push(addr_id);
         });
+               if (!addr_ids.length) return $q.when(null);
         return egCore.pcrud.search('aoa', {id: addr_ids},{},{ atomic: true}).then(function(addrs) {
             return egCore.env.absorbList(addrs, 'aoa');
         });