env: Stop fetching unnecessary app fields

Change-type: patch
This commit is contained in:
Otávio Jacobi 2023-08-16 10:37:58 -03:00
parent b8e190cd1d
commit f38e643cf0
2 changed files with 2 additions and 0 deletions

View File

@ -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) {

View File

@ -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) {