backend-common: more informative error message when no url reader is matched
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/backend-common': patch
|
||||
---
|
||||
|
||||
Use a more informative error message when URL reading isn't allowed due to no reader matching the target URL.
|
||||
@@ -52,7 +52,11 @@ export class UrlReaderPredicateMux implements UrlReader {
|
||||
}
|
||||
}
|
||||
|
||||
throw new NotAllowedError(`Reading from '${url}' is not allowed`);
|
||||
throw new NotAllowedError(
|
||||
`Reading from '${url}' is not allowed. ` +
|
||||
`You may need to configure an integration for the target host, or add it ` +
|
||||
`to the configured list of allowed hosts at 'backend.reading.allow'`,
|
||||
);
|
||||
}
|
||||
|
||||
async readUrl(
|
||||
|
||||
Reference in New Issue
Block a user