Skip to content

Commit d8817a5

Browse files
committed
fix(client): prioritise bearer auth
1 parent 80b711b commit d8817a5

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/finch_api/client.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,9 @@ class Client < FinchAPI::Internal::Transport::BaseClient
5858
#
5959
# @return [Hash{String=>String}]
6060
private def auth_headers
61-
{**bearer_auth, **basic_auth}
61+
return bearer_auth unless bearer_auth.empty?
62+
return basic_auth unless basic_auth.empty?
63+
{}
6264
end
6365

6466
# @api private

0 commit comments

Comments
 (0)