fixes
parent
12e64aeff7
commit
cd4ff2be15
|
|
@ -24,9 +24,10 @@
|
|||
const unlockDoor = (e, dID, aK, d) => {
|
||||
fetch(`${unlockUrl}?deviceID=${dID}&apiKey=${aK}&delay=${d}`)
|
||||
.then(response => response.json())
|
||||
.then(data => () {
|
||||
.then(data => {
|
||||
setTimeout(function() { messageContainer.innerHTML = "" }, 3000);
|
||||
messageContainer.innerHTML = data.message;
|
||||
return;
|
||||
})
|
||||
.catch(error => messageContainer.innerHTML = `Error: ${error}`)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue