android fix - return error from print
This commit is contained in:
parent
ad9a3bd515
commit
a7c4c9ae2c
@ -111,8 +111,11 @@ public class ZebraPrinter extends CordovaPlugin {
|
||||
}
|
||||
cordova.getThreadPool().execute(new Runnable() {
|
||||
public void run() {
|
||||
instance.printCPCL(cpcl);
|
||||
callbackContext.success();
|
||||
if(instance.printCPCL(cpcl)){
|
||||
callbackContext.success();
|
||||
}else{
|
||||
callbackContext.error("Print Failed. Printer Likely Disconnected.");
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user