This commit is contained in:
Douglas Barone 2022-04-11 15:32:42 -04:00
parent 2c0e6094b0
commit f33d3847d7

View File

@ -20,7 +20,7 @@ const WifiDevice = {
if (!parent.accessPointId && parent.apName) {
try {
await prisma.wifiDevice.update({
where: { id: parent.accessPointId }, data: {
where: { id: parent.id }, data: {
accessPoint: {
connect: {
hostname: parent.apName
@ -31,7 +31,7 @@ const WifiDevice = {
} catch (e) {
logError({
tags: ['wifiDevice', 'accessPoint'],
message: `Failed to connect ${parent.mac} to access point ${parent.apName}`,
message: `Failed to connect ${parent} to access point ${parent.apName}`,
})
}
}