summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDevlin Junker <devlin.junker@gmail.com>2023-10-04 15:16:48 -0700
committerBenjamin Brahmer <info@b-brahmer.de>2023-10-06 08:18:41 +0200
commit498c001bd35553d68b9332a971fd22afccdfdefa (patch)
tree0095b3bd36dc83853bb00e15daa955b518d09e8d /src
parent00d1d65ea462030bc7d599dc2ee2110fcdd183df (diff)
cleanup
Signed-off-by: Devlin Junker <devlin.junker@gmail.com>
Diffstat (limited to 'src')
-rw-r--r--src/store/app.ts12
-rw-r--r--src/store/index.ts4
-rw-r--r--src/types/MutationTypes.ts4
3 files changed, 11 insertions, 9 deletions
diff --git a/src/store/app.ts b/src/store/app.ts
index 928c57c7d..5b7f4c8dc 100644
--- a/src/store/app.ts
+++ b/src/store/app.ts
@@ -1,13 +1,11 @@
+import { APPLICATION_MUTATION_TYPES } from '../types/MutationTypes'
+
export const APPLICATION_ACTION_TYPES = {
SET_ERROR_MESSAGE: 'SET_ERROR_MESSAGE',
}
-export const APPLICATION_MUTATION_TYPES = {
- SET_ERROR: 'SET_ERROR',
-}
-
type AppInfoState = {
- error?: any;
+ error?: Error;
}
const state: AppInfoState = {
@@ -21,7 +19,7 @@ const getters = {
}
export const actions = {
- // async [APPLICATION_ACTION_TYPES.SET_ERROR_MESSAGE]({ commit }: ActionParams) {
+ // async [APPLICATION_ACTION_TYPES...]({ commit }: ActionParams) {
// },
}
@@ -29,7 +27,7 @@ export const actions = {
export const mutations = {
[APPLICATION_MUTATION_TYPES.SET_ERROR](
state: AppInfoState,
- error: any,
+ error: Error,
) {
state.error = error
},
diff --git a/src/store/index.ts b/src/store/index.ts
index 34fae2831..2eea645d9 100644
--- a/src/store/index.ts
+++ b/src/store/index.ts
@@ -2,9 +2,9 @@ import { Folder } from '../types/Folder'
import { Feed } from '../types/Feed'
import feeds, { FEED_ACTION_TYPES } from './feed'
import folders, { FOLDER_ACTION_TYPES } from './folder'
-import { FOLDER_MUTATION_TYPES, FEED_MUTATION_TYPES, FEED_ITEM_MUTATION_TYPES } from '../types/MutationTypes'
+import { FOLDER_MUTATION_TYPES, FEED_MUTATION_TYPES, FEED_ITEM_MUTATION_TYPES, APPLICATION_MUTATION_TYPES } from '../types/MutationTypes'
import items, { FEED_ITEM_ACTION_TYPES, ItemState } from './item'
-import app, { APPLICATION_ACTION_TYPES, APPLICATION_MUTATION_TYPES } from './app'
+import app, { APPLICATION_ACTION_TYPES } from './app'
export const MUTATIONS = {
...APPLICATION_MUTATION_TYPES,
diff --git a/src/types/MutationTypes.ts b/src/types/MutationTypes.ts
index b427821cd..a6cf3478e 100644
--- a/src/types/MutationTypes.ts
+++ b/src/types/MutationTypes.ts
@@ -31,3 +31,7 @@ export const FEED_ITEM_MUTATION_TYPES = {
SET_ALL_LOADED: 'SET_ALL_LOADED',
SET_LAST_ITEM_LOADED: 'SET_LAST_ITEM_LOADED',
}
+
+export const APPLICATION_MUTATION_TYPES = {
+ SET_ERROR: 'SET_ERROR',
+}