         _emitter.on 'hull.auth.login', (me)-> _reporting.track('hull.auth.login', me)
         _emitter.on 'hull.auth.logout', ()-> _reporting.track('hull.auth.logout')
 
-        resolveUserPromise = (promise)->
+        handleUserPromise = (promise)->
           promise.then (user)->
             _emitter.emit('hull.auth.login', user)
           , (error) ->
             _emitter.emit('hull.auth.fail', error)
 
           promise
+
+        noCurentUserDeferred = promises.deferred()
+        noCurentUserDeferred.reject(
+          reason: 'no_current_user',
+          message: 'User must be logged in to perform this action'
+        )
 
         created =
           config: configParser(config)

          flag: _reporting.flag
          api: api.api
          currentUser: currentUser(_emitter)
          signup: (args...)->
            resolveUserPromise(api.auth.signup(args...))
          login: (args...)->
            if (api.auth.isAuthenticating())
              return console.info "Authentication is in progress. Use `Hull.on('hull.auth.login', fn)` to call `fn` when done."

            resolveUserPromise(api.auth.login(args...))
          logout: api.auth.logout
          linkIdentity: (provider, opts={}, callback=->)->
            options = _.extend opts, { mode: 'connect' }
            created.login provider, options, callback
          unlinkIdentity: (provider, callback=->)->
            promise = api.api("me/identities/#{provider}", 'delete').then(api.api.bind(api, 'me'))
            promise.then callback
            promise.then _emitter.emit.bind(_emitter, 'hull.auth.login')
          util:
            entity: entity
            eventEmitter: _emitter

define [
  'underscore'
  'lib/utils/promises',
  'lib/utils/emitter',
  'lib/api/api',
  'lib/api/reporting',
  'lib/utils/entity',
  'lib/utils/config',
  'lib/api/current-user'
  ], (_, promises, emitter, api, reporting, entity, configParser, currentUser)->

    create = (config)->
      _emitter = emitter()
