From 5e13a107be47712b04de8153cb48ea1e1d843ced Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Fri, 4 Jan 2019 21:27:45 +0000 Subject: [PATCH] --- ayanova/src/api/apimeta.js | 19 ------------------- ayanova/src/api/apiutil.js | 1 - ayanova/src/api/getAPIItem.js | 27 --------------------------- ayanova/src/views/About.vue | 6 +++--- 4 files changed, 3 insertions(+), 50 deletions(-) delete mode 100644 ayanova/src/api/apimeta.js delete mode 100644 ayanova/src/api/getAPIItem.js diff --git a/ayanova/src/api/apimeta.js b/ayanova/src/api/apimeta.js deleted file mode 100644 index 0baaf956..00000000 --- a/ayanova/src/api/apimeta.js +++ /dev/null @@ -1,19 +0,0 @@ -/* xeslint-disable */ -import apiUtil from "./apiutil"; - -export default { - fetchAPIInfo() { - return new Promise(function(resolve, reject) { - //step 2: get it - fetch(apiUtil.APIUrl("ServerInfo"), apiUtil.fetchGetOptions()) - .then(apiUtil.status) - .then(apiUtil.json) - .then(response => { - resolve(response); - }) - .catch(function(error) { - reject(error); - }); - }); - } -}; diff --git a/ayanova/src/api/apiutil.js b/ayanova/src/api/apiutil.js index cbd4d436..16df839d 100644 --- a/ayanova/src/api/apiutil.js +++ b/ayanova/src/api/apiutil.js @@ -179,7 +179,6 @@ export default { "API error: GET route =" + route + ", message =" + error.message; store.commit("logItem", errorMessage); alert("Error: " + errorMessage); - reject(error); }); }); diff --git a/ayanova/src/api/getAPIItem.js b/ayanova/src/api/getAPIItem.js deleted file mode 100644 index 71494763..00000000 --- a/ayanova/src/api/getAPIItem.js +++ /dev/null @@ -1,27 +0,0 @@ -/* xeslint-disable */ -import apiUtil from "./apiutil"; -import store from "../store"; -export default { - get(route) { - return new Promise(function(resolve, reject) { - fetch(apiUtil.APIUrl(route), apiUtil.fetchGetOptions()) - .then(apiUtil.status) - .then(apiUtil.json) - .then(response => { - //For now, assuming that all returns that make it here have either an error or a data object attached to them - //debugger; - resolve(response); - }) - .catch(function(error) { - //fundamental error, can't proceed with this call - // debugger; - var errorMessage = - "API error: GET route =" + route + ", message =" + error.message; - store.commit("logItem", errorMessage); - alert("Error: " + errorMessage); - - reject(error); - }); - }); - } -}; diff --git a/ayanova/src/views/About.vue b/ayanova/src/views/About.vue index c11ae1d3..54732205 100644 --- a/ayanova/src/views/About.vue +++ b/ayanova/src/views/About.vue @@ -103,7 +103,7 @@