for barcode not set up
This patch was written by Bob Wicksall and posted to launchpad. I've
tested on my own server and packaged it for review here.
The fix allows a patron to log into the self-check interface with either
a barcode or a user name.
Signed-off-by: Terran McCanna <tmccanna@georgialibraries.org>
this.orgSettings[k] = settings[k].value;
}
- if(settings[SET_BARCODE_REGEX])
- this.patronBarcodeRegex = new RegExp(settings[SET_BARCODE_REGEX].value);
+ if(settings[SET_BARCODE_REGEX]) {
+ this.patronBarcodeRegex = new RegExp(settings[SET_BARCODE_REGEX].value)
+ } else {
+ this.patronBarcodeRegex = newRegExp(/^\d/);
+ // this assumes barcodes start with digits
+ }
// Subtract the timeout warning interval from the configured timeout
// so that when taken together they add up to the configured amount.