Skip to content

Commit 809db19

Browse files
committed
fix #464 uninitiated variable name
1 parent aa5199c commit 809db19

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/index.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,12 +48,6 @@ export default function feathersVuex(feathers, options: FeathersVuexOptions) {
4848
)
4949
}
5050

51-
if (!options.serverAlias) {
52-
throw new Error(
53-
`You must provide a 'serverAlias' in the options to feathersVuex`
54-
)
55-
}
56-
5751
// Setup the event handlers. By default they just return the value of `options.enableEvents`
5852
defaults.handleEvents = events.reduce((obj, eventName) => {
5953
obj[eventName] = () => options.enableEvents || true
@@ -62,6 +56,12 @@ export default function feathersVuex(feathers, options: FeathersVuexOptions) {
6256

6357
options = Object.assign({}, defaults, options)
6458

59+
if (!options.serverAlias) {
60+
throw new Error(
61+
`You must provide a 'serverAlias' in the options to feathersVuex`
62+
)
63+
}
64+
6565
addClient({ client: feathers, serverAlias: options.serverAlias })
6666

6767
const BaseModel = makeBaseModel(options)

0 commit comments

Comments
 (0)