mirror of
https://github.com/YMFE/yapi.git
synced 2025-03-07 14:16:52 +08:00
fix: 解决header冲突
This commit is contained in:
parent
a4bebf74cd
commit
a366506a7c
@ -89,14 +89,8 @@ ToolUser.propTypes={
|
||||
@connect(
|
||||
(state) => {
|
||||
return{
|
||||
<<<<<<< HEAD
|
||||
avatar: state.login.avatar,
|
||||
user: state.login.userName,
|
||||
uid: state.login.uid,
|
||||
=======
|
||||
user: state.user.userName,
|
||||
uid: state.user.uid,
|
||||
>>>>>>> 8c04198eb2dd2e6ddae9b815cc9a21b6436d8c76
|
||||
msg: null,
|
||||
login:state.user.isLogin
|
||||
}
|
||||
|
@ -19,7 +19,6 @@ class baseController {
|
||||
|
||||
async init(ctx) {
|
||||
this.$user = null;
|
||||
console.log(111111)
|
||||
let ignoreRouter = [
|
||||
'/user/login_by_token',
|
||||
'/user/login',
|
||||
|
@ -66,23 +66,22 @@ var baseController = function () {
|
||||
switch (_context.prev = _context.next) {
|
||||
case 0:
|
||||
this.$user = null;
|
||||
console.log(111111);
|
||||
ignoreRouter = ['/user/login_by_token', '/user/login', '/user/reg', '/user/status', '/user/logout'];
|
||||
|
||||
if (!(ignoreRouter.indexOf(ctx.path) > -1)) {
|
||||
_context.next = 7;
|
||||
_context.next = 6;
|
||||
break;
|
||||
}
|
||||
|
||||
this.$auth = true;
|
||||
_context.next = 9;
|
||||
_context.next = 8;
|
||||
break;
|
||||
|
||||
case 7:
|
||||
_context.next = 9;
|
||||
case 6:
|
||||
_context.next = 8;
|
||||
return this.checkLogin(ctx);
|
||||
|
||||
case 9:
|
||||
case 8:
|
||||
case 'end':
|
||||
return _context.stop();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user