fix: applications API writing to unavailable models

when $useBuildServer is set, $application->settings model does not yet exist. This change ensures the models exist before accessing them.
This commit is contained in:
SierraJC
2024-12-14 12:58:11 +11:00
parent e7ffeda8e0
commit 00c93aa8b0
3 changed files with 140 additions and 31 deletions

View File

@@ -246,8 +246,14 @@ paths:
description: 'Use build server.'
type: object
responses:
'200':
'201':
description: 'Application created successfully.'
content:
application/json:
schema:
properties:
uuid: { type: string }
type: object
'401':
$ref: '#/components/responses/401'
'400':
@@ -475,8 +481,14 @@ paths:
description: 'Use build server.'
type: object
responses:
'200':
'201':
description: 'Application created successfully.'
content:
application/json:
schema:
properties:
uuid: { type: string }
type: object
'401':
$ref: '#/components/responses/401'
'400':
@@ -704,8 +716,14 @@ paths:
description: 'Use build server.'
type: object
responses:
'200':
'201':
description: 'Application created successfully.'
content:
application/json:
schema:
properties:
uuid: { type: string }
type: object
'401':
$ref: '#/components/responses/401'
'400':
@@ -880,8 +898,14 @@ paths:
description: 'Use build server.'
type: object
responses:
'200':
'201':
description: 'Application created successfully.'
content:
application/json:
schema:
properties:
uuid: { type: string }
type: object
'401':
$ref: '#/components/responses/401'
'400':
@@ -1047,8 +1071,14 @@ paths:
description: 'Use build server.'
type: object
responses:
'200':
'201':
description: 'Application created successfully.'
content:
application/json:
schema:
properties:
uuid: { type: string }
type: object
'401':
$ref: '#/components/responses/401'
'400':
@@ -1105,8 +1135,14 @@ paths:
description: 'Use build server.'
type: object
responses:
'200':
'201':
description: 'Application created successfully.'
content:
application/json:
schema:
properties:
uuid: { type: string }
type: object
'401':
$ref: '#/components/responses/401'
'400':