소스 검색

Bug fix: cookies were not working across subdomains.

Lee Morgan 5 년 전
부모
커밋
e72fd50691
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      app.js

+ 2 - 1
app.js

@@ -38,7 +38,8 @@ app.use(session({
     secret: "Super Secret Subline Subliminally Saving Secrets So Sneaky Snakes Stay Sullen. Simply Superb.",
     cookie: {secure: true},
     saveUninitialized: true,
-    resave: false
+    resave: false,
+    domain: process.env.COOKIE_DOMAIN
 }));
 app.use(express.urlencoded({extended: true}));
 app.use(express.json());