Merge pull request #24328 from secustor/fix/unprocessed-entities-owner

fix(plugins/catalog-backend-module-unprocessed): correctly translate owner to string in case of nullish value
This commit is contained in:
Fredrik Adelöw
2024-04-30 13:00:59 +02:00
committed by GitHub
2 changed files with 9 additions and 2 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-catalog-backend-module-unprocessed': patch
---
Correctly convert owner to string in case owner has not been provided
@@ -162,7 +162,8 @@ export class UnprocessedEntitiesModule {
return res.json(
await this.unprocessed({
reason: 'failed',
owner: String(req.query.owner),
owner:
typeof req.query.owner === 'string' ? req.query.owner : undefined,
}),
);
})
@@ -170,7 +171,8 @@ export class UnprocessedEntitiesModule {
return res.json(
await this.unprocessed({
reason: 'pending',
owner: String(req.query.owner),
owner:
typeof req.query.owner === 'string' ? req.query.owner : undefined,
}),
);
})