Skip to content

Commit

Permalink
fix: unauthorized if delegated access has expired (#296) [PPT-731]
Browse files Browse the repository at this point in the history
  • Loading branch information
stakach authored Sep 6, 2023
1 parent d92b21b commit d711bef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/controllers/utilities/multi_tenant.cr
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ module Utils::MultiTenant
tenant.place_calendar_client token.token, token.expires
rescue error
Log.error(exception: error) { "error obtaining resource token" }
raise Error::NotImplemented.new("no available delegated resource token for user #{user_token.user.email}")
raise Error::Unauthorized.new("no available delegated resource token for user #{user_token.user.email}")
end
else
# Use the credentials in the database
Expand Down

0 comments on commit d711bef

Please sign in to comment.