Topic: Issue unbinding a driver from a unit with JavaScript API
Hi Wialon,
I am using the JavaScript API to bind drivers to units without any issues. I'm using the bindDriverToUnit() method. In the documentation for this method (https://sdk.wialon.com/api/index.html#w … hod_public), in the parameters section, it says that for the "driver" parameter, it "can be null to unbind driver from unit." But when I pass null as the argument for this driver parameter I get an error back from Wialon about invalid input.
I am using the below code (which works fine for binding a driver to an empty or an already bound unit):
// attempt to bind the driver to a unit
pcbWialonResource.bindDriverToUnit(wialonDriverObjectToBind, wialonUnitObjectToBindDriverTo, 0, shouldBind,
qx.lang.Function.bind(function(pcbWialonResource, wialonDriverObjectToBind, code, result) {