diff --git a/redash/handlers/embed.py b/redash/handlers/embed.py index 301bd14ee4..3a9cadf596 100644 --- a/redash/handlers/embed.py +++ b/redash/handlers/embed.py @@ -51,17 +51,21 @@ def embed(query_id, visualization_id, org_slug=None): @login_required @csp_allows_embeding def public_dashboard(token, org_slug=None): + logger.info(f"Inside >>> public_dashboard : {token}") + logger.info(f"current_user.is_api_user() : {current_user.is_api_user()}") if current_user.is_api_user(): dashboard = current_user.object else: api_key = get_object(models.ApiKey.get_by_api_key, token) + logger.info(f" api_key : {api_key}") if api_key: dashboard = api_key.object logger.info('dashboard %s', dashboard) else: # Here if the object is not found using the api_key try to decode the token using salt and see if it's valid decoded_token = decode_token(token) + logger.info(f" decoded_token : {decoded_token}") if decode_token: dashboard_id = decoded_token.get('id') logger.info('Extracted dashboard id from the token : %s', dashboard_id)