File tree Expand file tree Collapse file tree 1 file changed +18
-3
lines changed Expand file tree Collapse file tree 1 file changed +18
-3
lines changed Original file line number Diff line number Diff line change @@ -467,7 +467,12 @@ impl Identity {
467467 } ,
468468 Identity :: Apple ( handle) => {
469469 hasher. update ( b"apple" ) ;
470- hasher. update ( String :: from_utf8 ( handle. inner . to_vec ( ) ) . unwrap_or_default ( ) ) ;
470+ hasher. update (
471+ String :: from_utf8 ( handle. inner . to_vec ( ) )
472+ . unwrap_or_default ( )
473+ . to_lowercase ( )
474+ . as_bytes ( ) ,
475+ ) ;
471476 } ,
472477 Identity :: Email ( handle) => {
473478 hasher. update ( b"email" ) ;
@@ -480,7 +485,12 @@ impl Identity {
480485 } ,
481486 Identity :: Google ( handle) => {
482487 hasher. update ( b"google" ) ;
483- hasher. update ( String :: from_utf8 ( handle. inner . to_vec ( ) ) . unwrap_or_default ( ) ) ;
488+ hasher. update (
489+ String :: from_utf8 ( handle. inner . to_vec ( ) )
490+ . unwrap_or_default ( )
491+ . to_lowercase ( )
492+ . as_bytes ( ) ,
493+ ) ;
484494 } ,
485495 Identity :: Pumpx ( handle) => {
486496 // TODO: this type will be removed.
@@ -489,7 +499,12 @@ impl Identity {
489499 } ,
490500 Identity :: Passkey ( handle) => {
491501 hasher. update ( b"passkey" ) ;
492- hasher. update ( String :: from_utf8 ( handle. inner . to_vec ( ) ) . unwrap_or_default ( ) ) ;
502+ hasher. update (
503+ String :: from_utf8 ( handle. inner . to_vec ( ) )
504+ . unwrap_or_default ( )
505+ . to_lowercase ( )
506+ . as_bytes ( ) ,
507+ ) ;
493508 } ,
494509 }
495510
You can’t perform that action at this time.
0 commit comments