aboutsummaryrefslogtreecommitdiffstats
path: root/src/api
diff options
context:
space:
mode:
authorLibravatar Stefan Malzner <stefan@adlk.io>2017-11-23 16:17:34 +0100
committerLibravatar GitHub <noreply@github.com>2017-11-23 16:17:34 +0100
commitabca425e4a7b63be93132067bc335e8b6b39c2b2 (patch)
treee386f3e5d4c1c1caff19e3555e7ed1ce93e625f6 /src/api
parentreplace typeform (diff)
parentAdd windows notification fix to changelog (diff)
downloadferdium-app-abca425e4a7b63be93132067bc335e8b6b39c2b2.tar.gz
ferdium-app-abca425e4a7b63be93132067bc335e8b6b39c2b2.tar.zst
ferdium-app-abca425e4a7b63be93132067bc335e8b6b39c2b2.zip
Merge pull request #330 from meetfranz/developv5.0.0-beta.14
Beta 14
Diffstat (limited to 'src/api')
-rw-r--r--src/api/server/LocalApi.js4
-rw-r--r--src/api/server/ServerApi.js2
2 files changed, 4 insertions, 2 deletions
diff --git a/src/api/server/LocalApi.js b/src/api/server/LocalApi.js
index 79ac6e12f..eba236f16 100644
--- a/src/api/server/LocalApi.js
+++ b/src/api/server/LocalApi.js
@@ -1,3 +1,5 @@
1import SettingsModel from '../../models/Settings';
2
1export default class LocalApi { 3export default class LocalApi {
2 // App 4 // App
3 async updateAppSettings(data) { 5 async updateAppSettings(data) {
@@ -13,7 +15,7 @@ export default class LocalApi {
13 async getAppSettings() { 15 async getAppSettings() {
14 const settingsString = localStorage.getItem('app'); 16 const settingsString = localStorage.getItem('app');
15 try { 17 try {
16 const settings = JSON.parse(settingsString) || {}; 18 const settings = new SettingsModel(JSON.parse(settingsString) || {});
17 console.debug('LocalApi::getAppSettings resolves', settings); 19 console.debug('LocalApi::getAppSettings resolves', settings);
18 20
19 return settings; 21 return settings;
diff --git a/src/api/server/ServerApi.js b/src/api/server/ServerApi.js
index 932b70cdc..f25f02eaa 100644
--- a/src/api/server/ServerApi.js
+++ b/src/api/server/ServerApi.js
@@ -374,7 +374,7 @@ export default class ServerApi {
374 // News 374 // News
375 async getLatestNews() { 375 async getLatestNews() {
376 // eslint-disable-next-line 376 // eslint-disable-next-line
377 const request = await window.fetch(`${SERVER_URL}/${API_VERSION}/news?platform=${os.platform()}&arch=${os.arch()}version=${app.getVersion()}`, 377 const request = await window.fetch(`${SERVER_URL}/${API_VERSION}/news?platform=${os.platform()}&arch=${os.arch()}&version=${app.getVersion()}`,
378 this._prepareAuthRequest({ 378 this._prepareAuthRequest({
379 method: 'GET', 379 method: 'GET',
380 })); 380 }));