device register: Stop fetching unnecessary app fields

Change-type: patch
This commit is contained in:
Thodoris Greasidis 2023-05-20 00:59:20 +03:00
parent 15dac6f194
commit 8b3235ab2b

View File

@ -78,7 +78,9 @@ export default class DeviceRegisterCmd extends Command {
const balena = getBalenaSdk();
const application = await getApplication(balena, params.fleet);
const application = await getApplication(balena, params.fleet, {
$select: ['id', 'slug'],
});
const uuid = options.uuid ?? balena.models.device.generateUniqueKey();
console.info(`Registering to ${application.slug}: ${uuid}`);