mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-11-21 17:26:29 -05:00
fix(frontend): improve expected origin error message
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
parent
d2a839b93b
commit
e953a5115a
1 changed files with 3 additions and 1 deletions
|
@ -38,7 +38,9 @@ export const ExpectedOriginBoundary: React.FC<ExpectedOriginBoundaryProps> = ({
|
|||
const currentOrigin = buildOriginFromHeaders()
|
||||
|
||||
if (new URL(expectedOrigin).origin !== currentOrigin) {
|
||||
return <span>{`You can't open this page using this URL. For this endpoint "${expectedOrigin}" is expected.`}</span>
|
||||
return (
|
||||
<span>{`You can't open this page using this URL. For this endpoint "${expectedOrigin}" is expected but got "${currentOrigin}".`}</span>
|
||||
)
|
||||
}
|
||||
return children
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue