Make deviceOption required

This commit is contained in:
Juan Cruz Viotti 2015-01-08 13:30:15 -03:00
parent b5701f53f5
commit 5ec4abc710
2 changed files with 1 additions and 3 deletions

View File

@ -5,9 +5,6 @@ helpers = require('../helpers/helpers')
resin = require('resin-sdk')
exports.set = permissions.user (params, options) ->
if not options.device?
errors.handle(new Error('You have to specify a device'))
async.waterfall([
(callback) ->

View File

@ -65,6 +65,7 @@ deviceOption =
parameter: 'device'
description: 'device id'
alias: [ 'd', 'dev' ]
required: 'You have to specify a device'
# ---------- Auth Module ----------
capitano.command