Skip to content

Commit

Permalink
fix: launch replay domain button (#25806)
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
2 people authored and timgl committed Oct 25, 2024
1 parent d0eea88 commit 2d36fd1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,14 @@ export function AuthorizedUrlList({
<>
<LemonButton
icon={<IconOpenInApp />}
to={launchUrl(keyedURL.url)}
to={
// toolbar urls are sent through the backend to be validated
// and have toolbar auth information added
type === AuthorizedUrlListType.TOOLBAR_URLS
? launchUrl(keyedURL.url)
: // other urls are simply opened directly
keyedURL.url
}
targetBlank
tooltip={
type === AuthorizedUrlListType.TOOLBAR_URLS
Expand Down
6 changes: 0 additions & 6 deletions posthog/api/user.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
from typing import Any, Optional, cast

import jwt
import posthoganalytics
import requests
import structlog
from django.conf import settings
Expand Down Expand Up @@ -501,11 +500,6 @@ def redirect_to_site(request):

if not team or not unparsed_hostname_in_allowed_url_list(team.app_urls, app_url):
REDIRECT_TO_SITE_FAILED_COUNTER.inc()
posthoganalytics.capture(
request.user.distinct_id,
"redirect_to_site_failed",
{"app_url": app_url, "app_urls": team.app_urls, "team_id": team.id},
)
logger.error(
"can_only_redirect_to_permitted_domain", permitted_domains=team.app_urls, app_url=app_url, team_id=team.id
)
Expand Down

0 comments on commit 2d36fd1

Please sign in to comment.