mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-02 19:55:18 +02:00
Merge pull request #878 from aleksas/fix/public-invite-info-dev
fix(web): allow public invite info fetches
This commit is contained in:
commit
bb18f37c1b
1 changed files with 2 additions and 1 deletions
|
|
@ -91,7 +91,8 @@ class BaseApiService {
|
||||||
// Validate the bearer token
|
// Validate the bearer token
|
||||||
const isNoAuthEndpoint =
|
const isNoAuthEndpoint =
|
||||||
this.noAuthEndpoints.includes(url) ||
|
this.noAuthEndpoints.includes(url) ||
|
||||||
this.noAuthPrefixes.some((prefix) => url.startsWith(prefix));
|
this.noAuthPrefixes.some((prefix) => url.startsWith(prefix)) ||
|
||||||
|
/^\/api\/v1\/invites\/[^/]+\/info$/.test(url);
|
||||||
if (!this.bearerToken && !isNoAuthEndpoint) {
|
if (!this.bearerToken && !isNoAuthEndpoint) {
|
||||||
throw new AuthenticationError("You are not authenticated. Please login again.");
|
throw new AuthenticationError("You are not authenticated. Please login again.");
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue