Commented out unused code in read_flow function

This commit is contained in:
Gabriel Luiz Freitas Almeida 2024-03-06 14:34:40 -03:00
commit 1dec624c61

View file

@ -89,14 +89,14 @@ def read_flow(
settings_service: "SettingsService" = Depends(get_settings_service), settings_service: "SettingsService" = Depends(get_settings_service),
): ):
"""Read a flow.""" """Read a flow."""
auth_settings = settings_service.auth_settings # auth_settings = settings_service.auth_settings
if auth_settings.AUTO_LOGIN: # if auth_settings.AUTO_LOGIN:
user_id = None # user_id = None
else: # else:
user_id = current_user.id # user_id = current_user.id
if user_flow := ( if user_flow := (
session.exec( session.exec(
select(Flow).where(Flow.id == flow_id, Flow.user_id == user_id) select(Flow).where(Flow.id == flow_id, Flow.user_id == current_user.id)
).first() ).first()
): ):
return user_flow return user_flow