Skip to content

Commit 1ff8ce9

Browse files
author
pbochenski
authored
Merge pull request #5 from netguru/develop
0.0.5 fixup
2 parents f6653ea + 744c0a3 commit 1ff8ce9

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

frontend/src/components/Dashboard.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,14 +103,14 @@ const Dashboard = () => {
103103
const saveClicked = async (sensor) => {
104104
console.log(sensor)
105105
if(sensor.isNew){
106-
const result = await fetch(`http://${BASE_URL}/add_sensor`, {
106+
await fetch(`http://${BASE_URL}/add_sensor`, {
107107
method: 'PUT',
108108
headers: {'Content-Type': 'application/json'},
109109
body: JSON.stringify(sensor)
110110
})
111111

112112
} else {
113-
const result = await fetch(`http://${BASE_URL}/modify_sensor/${sensor.id}`, {
113+
await fetch(`http://${BASE_URL}/modify_sensor/${sensor.id}`, {
114114
method: 'PATCH',
115115
headers: {'Content-Type': 'application/json'},
116116
body: JSON.stringify(sensor)
@@ -122,7 +122,7 @@ const Dashboard = () => {
122122

123123
const deleteClicked = async (sensor) => {
124124
console.log(sensor);
125-
const result = await fetch(`http://${BASE_URL}/remove_sensor/${sensor.id}`, {
125+
await fetch(`http://${BASE_URL}/remove_sensor/${sensor.id}`, {
126126
method: 'DELETE',
127127
headers: {'Content-Type': 'application/json'},
128128
});

frontend/src/views/EditTransform.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React, { useState, useEffect } from 'react';
1+
import React, { useState } from 'react';
22

33
const REMOVE = {
44
background: 'rgba(180, 0, 0, 0.2)',

0 commit comments

Comments
 (0)