Fotospiel GmbH entfernt, Jon Token des demo events gefixt + demoeventseeder. Favicon auf ".ico" gesetzt.
This commit is contained in:
@@ -298,8 +298,8 @@ class EventPublicController extends BaseController
|
||||
|
||||
return ApiError::response(
|
||||
'token_rate_limited',
|
||||
'Too Many Attempts',
|
||||
'Too many invalid join token attempts. Try again later.',
|
||||
$this->tokenErrorTitle('token_rate_limited'),
|
||||
__('api.join_tokens.invalid_attempts_message'),
|
||||
Response::HTTP_TOO_MANY_REQUESTS,
|
||||
array_merge($context, ['rate_limiter_key' => $rateLimiterKey])
|
||||
);
|
||||
@@ -333,21 +333,22 @@ class EventPublicController extends BaseController
|
||||
private function tokenErrorMessage(string $code): string
|
||||
{
|
||||
return match ($code) {
|
||||
'invalid_token' => 'The provided join token is invalid.',
|
||||
'token_expired' => 'The join token has expired.',
|
||||
'token_revoked' => 'The join token has been revoked.',
|
||||
default => 'Access denied.',
|
||||
'invalid_token' => __('api.join_tokens.invalid_message'),
|
||||
'token_expired' => __('api.join_tokens.expired_message'),
|
||||
'token_revoked' => __('api.join_tokens.revoked_message'),
|
||||
'token_rate_limited' => __('api.join_tokens.rate_limited_message'),
|
||||
default => __('api.join_tokens.default_message'),
|
||||
};
|
||||
}
|
||||
|
||||
private function tokenErrorTitle(string $code): string
|
||||
{
|
||||
return match ($code) {
|
||||
'invalid_token' => 'Invalid Join Token',
|
||||
'token_expired' => 'Join Token Expired',
|
||||
'token_revoked' => 'Join Token Revoked',
|
||||
'token_rate_limited' => 'Join Token Rate Limited',
|
||||
default => 'Access Denied',
|
||||
'invalid_token' => __('api.join_tokens.invalid_title'),
|
||||
'token_expired' => __('api.join_tokens.expired_title'),
|
||||
'token_revoked' => __('api.join_tokens.revoked_title'),
|
||||
'token_rate_limited' => __('api.join_tokens.rate_limited_title'),
|
||||
default => __('api.join_tokens.default_title'),
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user