diff options
author | Stefan Malzner <stefan@adlk.io> | 2018-11-15 12:25:36 +0100 |
---|---|---|
committer | Stefan Malzner <stefan@adlk.io> | 2018-11-15 12:25:36 +0100 |
commit | e109e62eef136feb17d5a8663fbd2b2355a6bf67 (patch) | |
tree | 7d40b506206f5e333b10f025942c1b7f45fd68cd /src | |
parent | fix(General): Convert many links from http to https (#967) @Stanzilla (diff) | |
parent | Add misty config (diff) | |
download | ferdium-app-e109e62eef136feb17d5a8663fbd2b2355a6bf67.tar.gz ferdium-app-e109e62eef136feb17d5a8663fbd2b2355a6bf67.tar.zst ferdium-app-e109e62eef136feb17d5a8663fbd2b2355a6bf67.zip |
Merge branch 'chore/update-dependencies' into develop
Diffstat (limited to 'src')
-rw-r--r-- | src/api/server/ServerApi.js | 2 | ||||
-rw-r--r-- | src/app.js | 2 | ||||
-rw-r--r-- | src/index.js | 5 | ||||
-rw-r--r-- | src/models/News.js | 8 | ||||
-rw-r--r-- | src/models/Plan.js | 4 | ||||
-rw-r--r-- | src/models/RecipePreview.js | 8 | ||||
-rw-r--r-- | src/models/Service.js | 2 | ||||
-rw-r--r-- | src/stores/SettingsStore.js | 2 | ||||
-rw-r--r-- | src/stores/UIStore.js | 2 |
9 files changed, 20 insertions, 15 deletions
diff --git a/src/api/server/ServerApi.js b/src/api/server/ServerApi.js index 353faa7f4..2e80e520b 100644 --- a/src/api/server/ServerApi.js +++ b/src/api/server/ServerApi.js | |||
@@ -35,7 +35,7 @@ module.paths.unshift( | |||
35 | ); | 35 | ); |
36 | 36 | ||
37 | const { app } = remote; | 37 | const { app } = remote; |
38 | const fetch = remote.require('electron-fetch'); | 38 | const { default: fetch } = remote.require('electron-fetch'); |
39 | 39 | ||
40 | const SERVER_URL = API; | 40 | const SERVER_URL = API; |
41 | const API_VERSION = 'v1'; | 41 | const API_VERSION = 'v1'; |
diff --git a/src/app.js b/src/app.js index 814bfacf1..43d0cf018 100644 --- a/src/app.js +++ b/src/app.js | |||
@@ -6,7 +6,7 @@ import { Provider } from 'mobx-react'; | |||
6 | import { syncHistoryWithStore, RouterStore } from 'mobx-react-router'; | 6 | import { syncHistoryWithStore, RouterStore } from 'mobx-react-router'; |
7 | import { Router, Route, hashHistory, IndexRedirect } from 'react-router'; | 7 | import { Router, Route, hashHistory, IndexRedirect } from 'react-router'; |
8 | 8 | ||
9 | import 'babel-polyfill'; | 9 | import '@babel/polyfill'; |
10 | import smoothScroll from 'smoothscroll-polyfill'; | 10 | import smoothScroll from 'smoothscroll-polyfill'; |
11 | 11 | ||
12 | import ServerApi from './api/server/ServerApi'; | 12 | import ServerApi from './api/server/ServerApi'; |
diff --git a/src/index.js b/src/index.js index 5ba901b89..5fbe3bc4f 100644 --- a/src/index.js +++ b/src/index.js | |||
@@ -19,6 +19,11 @@ const debug = require('debug')('App'); | |||
19 | let mainWindow; | 19 | let mainWindow; |
20 | let willQuitApp = false; | 20 | let willQuitApp = false; |
21 | 21 | ||
22 | // DEV MODE: Save user data into FranzDev | ||
23 | if (isDevMode) { | ||
24 | app.setPath('userData', path.join(app.getPath('appData'), 'FranzDev')); | ||
25 | } | ||
26 | |||
22 | // Ensure that the recipe directory exists | 27 | // Ensure that the recipe directory exists |
23 | fs.emptyDirSync(path.join(app.getPath('userData'), 'recipes', 'temp')); | 28 | fs.emptyDirSync(path.join(app.getPath('userData'), 'recipes', 'temp')); |
24 | fs.ensureFileSync(path.join(app.getPath('userData'), 'window-state.json')); | 29 | fs.ensureFileSync(path.join(app.getPath('userData'), 'window-state.json')); |
diff --git a/src/models/News.js b/src/models/News.js index a96e6550f..caf1d70e5 100644 --- a/src/models/News.js +++ b/src/models/News.js | |||
@@ -1,10 +1,10 @@ | |||
1 | // @flow | 1 | // @flow |
2 | 2 | ||
3 | export default class News { | 3 | export default class News { |
4 | id: string = ''; | 4 | id = ''; |
5 | message: string = ''; | 5 | message = ''; |
6 | type: string = 'primary'; | 6 | type = 'primary'; |
7 | sticky: bool = false; | 7 | sticky = false; |
8 | 8 | ||
9 | constructor(data) { | 9 | constructor(data) { |
10 | if (!data.id) { | 10 | if (!data.id) { |
diff --git a/src/models/Plan.js b/src/models/Plan.js index e77353824..c7b4a0962 100644 --- a/src/models/Plan.js +++ b/src/models/Plan.js | |||
@@ -1,11 +1,11 @@ | |||
1 | // @flow | 1 | // @flow |
2 | 2 | ||
3 | export default class Plan { | 3 | export default class Plan { |
4 | month: { | 4 | month = { |
5 | id: '', | 5 | id: '', |
6 | price: 0, | 6 | price: 0, |
7 | } | 7 | } |
8 | year: { | 8 | year = { |
9 | id: '', | 9 | id: '', |
10 | price: 0, | 10 | price: 0, |
11 | } | 11 | } |
diff --git a/src/models/RecipePreview.js b/src/models/RecipePreview.js index 525a5c4b5..7470d757a 100644 --- a/src/models/RecipePreview.js +++ b/src/models/RecipePreview.js | |||
@@ -1,10 +1,10 @@ | |||
1 | // @flow | 1 | // @flow |
2 | 2 | ||
3 | export default class RecipePreview { | 3 | export default class RecipePreview { |
4 | id: string = ''; | 4 | id = ''; |
5 | name: string = ''; | 5 | name = ''; |
6 | icon: string = ''; // TODO: check if this isn't replaced by `icons` | 6 | icon = ''; // TODO: check if this isn't replaced by `icons` |
7 | featured: bool = false; | 7 | featured = false; |
8 | 8 | ||
9 | constructor(data) { | 9 | constructor(data) { |
10 | if (!data.id) { | 10 | if (!data.id) { |
diff --git a/src/models/Service.js b/src/models/Service.js index bafb3f564..4f8767dbe 100644 --- a/src/models/Service.js +++ b/src/models/Service.js | |||
@@ -7,7 +7,7 @@ export default class Service { | |||
7 | recipe = ''; | 7 | recipe = ''; |
8 | webview = null; | 8 | webview = null; |
9 | timer = null; | 9 | timer = null; |
10 | events: {}; | 10 | events = {}; |
11 | 11 | ||
12 | isAttached = false; | 12 | isAttached = false; |
13 | 13 | ||
diff --git a/src/stores/SettingsStore.js b/src/stores/SettingsStore.js index d8519c609..9270a6481 100644 --- a/src/stores/SettingsStore.js +++ b/src/stores/SettingsStore.js | |||
@@ -68,7 +68,7 @@ export default class SettingsStore extends Store { | |||
68 | 68 | ||
69 | // Helper | 69 | // Helper |
70 | _migrate() { | 70 | _migrate() { |
71 | const legacySettings = localStorage.getItem('app'); | 71 | const legacySettings = localStorage.getItem('app') || {}; |
72 | 72 | ||
73 | if (!this.all.migration['5.0.0-beta.17-settings']) { | 73 | if (!this.all.migration['5.0.0-beta.17-settings']) { |
74 | this.actions.settings.update({ | 74 | this.actions.settings.update({ |
diff --git a/src/stores/UIStore.js b/src/stores/UIStore.js index b391bdcae..bee6c8bcf 100644 --- a/src/stores/UIStore.js +++ b/src/stores/UIStore.js | |||
@@ -26,7 +26,7 @@ export default class UIStore extends Store { | |||
26 | this.stores.router.push(settingsPath); | 26 | this.stores.router.push(settingsPath); |
27 | } | 27 | } |
28 | 28 | ||
29 | @action _closeSettings(): void { | 29 | @action _closeSettings() { |
30 | this.stores.router.push('/'); | 30 | this.stores.router.push('/'); |
31 | } | 31 | } |
32 | 32 | ||