zhuangyunsheng hai 1 ano
pai
achega
11e9f4d94f
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/router/index.js

+ 1 - 1
src/router/index.js

@@ -51,7 +51,7 @@ router.beforeEach(async (to, from, next) => {
 	let token = tool.cookie.get("TOKEN");
 
 	if (to.path === "/redirect") {
-		if (!token) {
+		if (to.query.userId) {
 			const { token, user } = await api.auth.oa.getUserToken(to.query);
 			tool.cookie.set("TOKEN", token);
 			tool.data.set("USER_INFO", user.user);