We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f855834 commit baf87eeCopy full SHA for baf87ee
1 file changed
packages/binding-modbus/src/modbus-client.ts
@@ -217,7 +217,7 @@ export default class ModbusClient implements ProtocolClient {
217
private generateFormFromURLPath(input: ModbusForm) {
218
const { pathname, searchParams: query } = new URL(input.href);
219
const pathComp = pathname.split("/");
220
- if ((pathComp.length < 3) || pathComp[1] ==='' || pathComp[2]==='') {
+ if (pathComp.length < 3 || pathComp[1] === "" || pathComp[2] === "") {
221
throw new Error("Malformed href: unitID and address must be defined");
222
}
223
input["modv:unitID"] = parseInt(pathComp[1], 10);
0 commit comments