diff options
author | Vijay A <vraravam@users.noreply.github.com> | 2022-07-02 05:13:38 +0530 |
---|---|---|
committer | Vijay Aravamudhan <vraravam@users.noreply.github.com> | 2022-07-02 06:19:03 +0530 |
commit | d16cc1f2c59818e53f28b4d6b4d27250331f15d7 (patch) | |
tree | 57bf4d149ec2be88dd0d351142998ce96db0d659 /src/api | |
parent | chore: correctly export/import ui elements (diff) | |
download | ferdium-app-d16cc1f2c59818e53f28b4d6b4d27250331f15d7.tar.gz ferdium-app-d16cc1f2c59818e53f28b4d6b4d27250331f15d7.tar.zst ferdium-app-d16cc1f2c59818e53f28b4d6b4d27250331f15d7.zip |
Use default exports instead of named exports
Diffstat (limited to 'src/api')
-rw-r--r-- | src/api/apiBase.ts | 4 | ||||
-rw-r--r-- | src/api/server/ServerApi.ts | 2 |
2 files changed, 2 insertions, 4 deletions
diff --git a/src/api/apiBase.ts b/src/api/apiBase.ts index d7cc9b810..c6e3c0ed8 100644 --- a/src/api/apiBase.ts +++ b/src/api/apiBase.ts | |||
@@ -13,7 +13,7 @@ import { | |||
13 | import { fixUrl } from '../helpers/url-helpers'; | 13 | import { fixUrl } from '../helpers/url-helpers'; |
14 | 14 | ||
15 | // Note: This cannot be used from the internal-server since we are not running within the context of a browser window | 15 | // Note: This cannot be used from the internal-server since we are not running within the context of a browser window |
16 | const apiBase = (withVersion = true) => { | 16 | export default function apiBase(withVersion = true) { |
17 | if ( | 17 | if ( |
18 | !(window as any).ferdium || | 18 | !(window as any).ferdium || |
19 | !(window as any).ferdium.stores.settings || | 19 | !(window as any).ferdium.stores.settings || |
@@ -33,8 +33,6 @@ const apiBase = (withVersion = true) => { | |||
33 | return fixUrl(withVersion ? `${url}/${API_VERSION}` : url); | 33 | return fixUrl(withVersion ? `${url}/${API_VERSION}` : url); |
34 | }; | 34 | }; |
35 | 35 | ||
36 | export default apiBase; | ||
37 | |||
38 | export function serverBase() { | 36 | export function serverBase() { |
39 | 37 | ||
40 | const serverType = (window as any).ferdium.stores.settings.all.app.server; | 38 | const serverType = (window as any).ferdium.stores.settings.all.app.server; |
diff --git a/src/api/server/ServerApi.ts b/src/api/server/ServerApi.ts index 935d7de3d..a636f3e0d 100644 --- a/src/api/server/ServerApi.ts +++ b/src/api/server/ServerApi.ts | |||
@@ -19,7 +19,7 @@ import RecipePreviewModel from '../../models/RecipePreview'; | |||
19 | import RecipeModel from '../../models/Recipe'; | 19 | import RecipeModel from '../../models/Recipe'; |
20 | import UserModel from '../../models/User'; | 20 | import UserModel from '../../models/User'; |
21 | 21 | ||
22 | import { sleep } from '../../helpers/async-helpers'; | 22 | import sleep from '../../helpers/async-helpers'; |
23 | 23 | ||
24 | import { SERVER_NOT_LOADED } from '../../config'; | 24 | import { SERVER_NOT_LOADED } from '../../config'; |
25 | import { userDataRecipesPath, userDataPath } from '../../environment-remote'; | 25 | import { userDataRecipesPath, userDataPath } from '../../environment-remote'; |