-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d335af0
commit c49832d
Showing
1 changed file
with
50 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -81,6 +81,56 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 | |
fmt.Println(userInfo) | ||
} | ||
``` | ||
- If you are using `thirdpartypasswordless.GetUsersByEmail`: | ||
|
||
Before: | ||
```go | ||
userInfo, err := thirdpartypasswordless.GetUsersByEmail("public", "[email protected]") | ||
``` | ||
|
||
After: | ||
```go | ||
thirdPartyUserInfo, err := thirdparty.GetUsersByEmail("public", "[email protected]") | ||
if err != nil { | ||
return | ||
} | ||
passwordlessUserInfo, err := passwordless.GetUserByEmail("public", "[email protected]") | ||
if err != nil { | ||
return | ||
} | ||
if passwordlessUserInfo != nil { | ||
fmt.Println(passwordlessUserInfo) | ||
} | ||
if len(thirdPartyUserInfo) > 0 { | ||
fmt.Println(thirdPartyUserInfo) | ||
} | ||
``` | ||
|
||
- If you are using `thirdpartypasswordless.GetUserById`: | ||
|
||
Before: | ||
```go | ||
userInfo, err := thirdpartypasswordless.GetUserById(userID) | ||
``` | ||
|
||
After: | ||
```go | ||
userInfo, err := thirdparty.GetUserByID(userID) | ||
if err != nil { | ||
// TODO: Handle error | ||
} | ||
if userInfo == nil { | ||
passwordlessUserInfo, err := passwordless.GetUserByID(userID) | ||
if err != nil { | ||
// TODO: Handle error | ||
} | ||
fmt.Println(passwordlessUserInfo) | ||
} else { | ||
fmt.Println(userInfo) | ||
} | ||
``` | ||
|
||
## [0.19.0] - 2024-05-01 | ||
|
||
|