mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-11-01 21:02:26 -05:00
[chore] Settings refactor fix 2 (#1357)
* fix emoji query tagging * fix proxy url for gts instance * fix: don't flash callback error on authorize flow
This commit is contained in:
parent
13e3aaaed1
commit
747683ba54
11 changed files with 37 additions and 31 deletions
|
|
@ -23,17 +23,12 @@ const { createSlice } = require("@reduxjs/toolkit");
|
|||
module.exports = createSlice({
|
||||
name: "oauth",
|
||||
initialState: {
|
||||
loginState: 'none'
|
||||
loginState: 'none',
|
||||
expectingRedirect: false
|
||||
},
|
||||
reducers: {
|
||||
setInstance: (state, { payload }) => {
|
||||
return {
|
||||
...state,
|
||||
...payload /* overrides instance, registration keys */
|
||||
};
|
||||
},
|
||||
authorize: (state) => {
|
||||
state.loginState = "callback";
|
||||
authorize: (state, { payload }) => {
|
||||
return payload; // overrides state
|
||||
},
|
||||
setToken: (state, { payload }) => {
|
||||
state.token = `${payload.token_type} ${payload.access_token}`;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue