Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuywap-node
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
郭成尧
7 years ago
Commit
8f400ffb0fb86ebfbf9f7ce232ef4c947f82e1a4
1 parent
7f5d0c98
clear-session
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
4 deletions
apps/passport/controllers/login.js
apps/passport/controllers/login.js
View file @
8f400ff
...
...
@@ -193,11 +193,16 @@ const common = {
if
(
req
.
session2
&&
req
.
session2
.
reset
)
{
req
.
session2
.
reset
();
}
if
(
req
.
session
&&
req
.
session
.
regenerate
)
{
return
req
.
session
.
regenerate
(()
=>
{
return
next
();
});
if
(
req
.
session
)
{
delete
req
.
session
.
SESSION_KEY
;
delete
req
.
session
.
AVATAR
;
delete
req
.
session
.
USER
;
delete
req
.
session
.
TOKEN
;
delete
req
.
session
.
LOGIN_UID
;
}
return
next
();
},
isLoginUser
:
(
req
,
res
,
next
)
=>
{
// 微信里边已经登录的时候,不再跳转登录
...
...
Please
register
or
login
to post a comment