This address the current issue in master, that causes bad barcodes
to fail silently.
To test
-------
[1] In the web staff client, go to Item Status and enter an item
barcode that is not present in the database. Note that no
warning message displayed.
[2] Apply the patch and repeat step 1. This tie, an 'Item Not Found'
message is displayed.
Signed-off by: Cesar Velez <cesar.velez@equinoxinitiative.org>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
return copyData;
});
}
+
return fetchCopy(barcode, id).then(function(res) {
+
+ if(!res.copy) { return $q.when(); }
+
return fetchCirc(copyData.copy).then(function(res) {
if (copyData.circ) {
return fetchSummary(copyData.circ).then(function() {
return service.retrieveCopyData(barcode, id)
.then(function(copyData) {
+ if(!copyData) { return $q.when(); }
//Make sure we're getting a completed copyData - no plain acp or circ objects
if (copyData.circ) {
// flesh circ_lib locally