mirror of
https://github.com/balena-io/balena-cli.git
synced 2024-12-23 23:42:24 +00:00
env: Stop fetching unnecessary app fields
Change-type: patch
This commit is contained in:
parent
b8e190cd1d
commit
f38e643cf0
1
lib/commands/env/add.ts
vendored
1
lib/commands/env/add.ts
vendored
@ -268,6 +268,7 @@ async function getServiceIdForApp(
|
||||
): Promise<number> {
|
||||
let serviceId: number | undefined;
|
||||
const services = await sdk.models.service.getAllByApplication(appSlug, {
|
||||
$select: 'id',
|
||||
$filter: { service_name: serviceName },
|
||||
});
|
||||
if (services.length > 0) {
|
||||
|
@ -208,6 +208,7 @@ async function validateServiceName(
|
||||
fleetSlug: string,
|
||||
) {
|
||||
const services = await sdk.models.service.getAllByApplication(fleetSlug, {
|
||||
$select: 'id',
|
||||
$filter: { service_name: serviceName },
|
||||
});
|
||||
if (services.length === 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user