From 3009e120a6a84ccb8cf2befbab691cec9e4b698c Mon Sep 17 00:00:00 2001 From: Rick Watson Date: Wed, 29 May 2019 23:59:57 +0100 Subject: [PATCH] fix ui --- interface/src/components/RestComponent.js | 4 ++-- interface/src/containers/WiFiNetworkScanner.js | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/interface/src/components/RestComponent.js b/interface/src/components/RestComponent.js index 288bd35..3edfe1d 100644 --- a/interface/src/components/RestComponent.js +++ b/interface/src/components/RestComponent.js @@ -61,9 +61,9 @@ export const restComponent = (endpointUrl, FormComponent) => { redirectingAuthorizedFetch(endpointUrl, { method: 'POST', body: JSON.stringify(this.state.data), - headers: new Headers({ + headers: { 'Content-Type': 'application/json' - }) + } }) .then(response => { if (response.status === 200) { diff --git a/interface/src/containers/WiFiNetworkScanner.js b/interface/src/containers/WiFiNetworkScanner.js index 0f064d5..fccfbc6 100644 --- a/interface/src/containers/WiFiNetworkScanner.js +++ b/interface/src/containers/WiFiNetworkScanner.js @@ -91,7 +91,6 @@ class WiFiNetworkScanner extends Component { this.setState({scanningForNetworks:false, networkList: json, errorMessage:null}) }) .catch(error => { - console.log(error.message); if (error.name !== RETRY_EXCEPTION_TYPE) { this.props.raiseNotification("Problem scanning: " + error.message); this.setState({scanningForNetworks:false, networkList: null, errorMessage:error.message});