Commit f89a6b7d authored by jim's avatar jim

fix #724 After registration, change the permission to user

parent 6e56098a
import { fakeRegister } from '../services/api'; import { fakeRegister } from '../services/api';
import { setAuthority } from '../utils/authority';
import { reloadAuthorized } from '../utils/Authorized';
export default { export default {
namespace: 'register', namespace: 'register',
...@@ -19,6 +21,8 @@ export default { ...@@ -19,6 +21,8 @@ export default {
reducers: { reducers: {
registerHandle(state, { payload }) { registerHandle(state, { payload }) {
setAuthority('user');
reloadAuthorized();
return { return {
...state, ...state,
status: payload.status, status: payload.status,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment