mirror of
https://github.com/balena-io/balena-cli.git
synced 2025-01-31 08:25:36 +00:00
Fix lodash bugs in device move & quickstart
Change-Type: patch
This commit is contained in:
parent
8980bc704a
commit
492e35e5c2
@ -249,7 +249,7 @@ exports.move = {
|
||||
patterns = require('../utils/patterns');
|
||||
return resin.models.device.get(params.uuid).then(function(device) {
|
||||
return options.application || patterns.selectApplication(function(application) {
|
||||
return _.all([application.device_type === device.device_type, device.application_name !== application.app_name]);
|
||||
return _.every([application.device_type === device.device_type, device.application_name !== application.app_name]);
|
||||
});
|
||||
}).tap(function(application) {
|
||||
return resin.models.device.move(params.uuid, application);
|
||||
|
@ -24,7 +24,7 @@ exports.getGroupDefaults = function(group) {
|
||||
_ = require('lodash');
|
||||
return _.chain(group).get('options').map(function(question) {
|
||||
return [question.name, question["default"]];
|
||||
}).object().value();
|
||||
}).fromPairs().value();
|
||||
};
|
||||
|
||||
exports.stateToString = function(state) {
|
||||
|
@ -343,7 +343,7 @@ exports.move =
|
||||
|
||||
resin.models.device.get(params.uuid).then (device) ->
|
||||
return options.application or patterns.selectApplication (application) ->
|
||||
return _.all [
|
||||
return _.every [
|
||||
application.device_type is device.device_type
|
||||
device.application_name isnt application.app_name
|
||||
]
|
||||
|
@ -23,7 +23,7 @@ exports.getGroupDefaults = (group) ->
|
||||
.get('options')
|
||||
.map (question) ->
|
||||
return [ question.name, question.default ]
|
||||
.object()
|
||||
.fromPairs()
|
||||
.value()
|
||||
|
||||
exports.stateToString = (state) ->
|
||||
|
Loading…
x
Reference in New Issue
Block a user