mirror of
https://github.com/wassname/talk.git
synced 2026-08-05 13:30:26 +08:00
[next] Support login and logout for TalkStreamEmbed (#2081)
* feat: Support login and logout for TalkStreamEmbed * fix: better test names * fix: remove obsolete line
This commit is contained in:
@@ -18,7 +18,7 @@ export async function commit(
|
||||
input: SetAuthTokenInput,
|
||||
{ localStorage, clearSession }: TalkContext
|
||||
) {
|
||||
return await commitLocalUpdatePromisified(environment, async store => {
|
||||
await commitLocalUpdatePromisified(environment, async store => {
|
||||
setAuthTokenInLocalState(input.authToken, store);
|
||||
if (input.authToken) {
|
||||
await localStorage.setItem("authToken", input.authToken);
|
||||
@@ -31,6 +31,6 @@ export async function commit(
|
||||
}
|
||||
|
||||
export const withSetAuthTokenMutation = createMutationContainer(
|
||||
"setCommentID",
|
||||
"setAuthToken",
|
||||
commit
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user