mirror of
https://github.com/balena-io/balena-cli.git
synced 2024-12-18 21:27:51 +00:00
Get rid of messages module
This commit is contained in:
parent
3db13f6329
commit
912ebf6752
@ -1,6 +1,5 @@
|
||||
_ = require('lodash')
|
||||
resin = require('../resin')
|
||||
messages = require('../messages/messages')
|
||||
|
||||
exports.failIfNotLoggedIn = (fn, onError) ->
|
||||
return ->
|
||||
@ -8,7 +7,7 @@ exports.failIfNotLoggedIn = (fn, onError) ->
|
||||
resin.auth.isLoggedIn (isLoggedIn) ->
|
||||
|
||||
if not isLoggedIn
|
||||
error = new Error(messages.errors.loginRequired)
|
||||
error = new Error('You have to log in')
|
||||
if onError?
|
||||
return onError(error)
|
||||
else
|
||||
|
@ -1,4 +0,0 @@
|
||||
module.exports =
|
||||
|
||||
errors:
|
||||
loginRequired: 'You have to log in'
|
Loading…
Reference in New Issue
Block a user