Skip to content

Commit

Permalink
Fix Google login
Browse files Browse the repository at this point in the history
  • Loading branch information
omarroth committed Feb 5, 2019
1 parent f225d38 commit 699f85e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/invidious.cr
Original file line number Diff line number Diff line change
Expand Up @@ -814,7 +814,7 @@ post "/login" do |env|

if challenge_results[0][-1][0].as_a?
# Prefer Authenticator app and SMS over unsupported protocols
if challenge_results[0][-1][0][0][8] != 6 || challenge_results[0][-1][0][0][8] != 9
if challenge_results[0][-1][0][0][8] != 6 && challenge_results[0][-1][0][0][8] != 9
tfa = challenge_results[0][-1][0].as_a.select { |auth_type| auth_type[8] == 6 || auth_type[8] == 9 }[0]
select_challenge = "[#{challenge_results[0][-1][0].as_a.index(tfa).not_nil!}]"

Expand Down

0 comments on commit 699f85e

Please sign in to comment.