slight pairing fix
parent
1dd752b3b2
commit
b383fe5903
|
@ -13,7 +13,7 @@ async function pairDevice(account, qr_string) {
|
||||||
var qrCodeParts = qr_string.split("--");
|
var qrCodeParts = qr_string.split("--");
|
||||||
let deviceQuery;
|
let deviceQuery;
|
||||||
let pairJWT;
|
let pairJWT;
|
||||||
if (qrCodeParts.length > 0) {
|
if (qrCodeParts.length > 1) {
|
||||||
deviceQuery = await models_orm.models.device.findOne({ where: { serial: qrCodeParts[1] }});
|
deviceQuery = await models_orm.models.device.findOne({ where: { serial: qrCodeParts[1] }});
|
||||||
pairJWT = qrCodeParts[2];
|
pairJWT = qrCodeParts[2];
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue