mirror of
https://github.com/linux-odyssey/linux-odyssey.git
synced 2026-11-08 11:30:12 +08:00
Merge pull request #28 from linux-odyssey/fix-cookie
fix: change cookie setting, prevent form trigger twice
This commit is contained in:
2 files changed
+3
-3
No files matched your search
@@ -155,7 +155,7 @@ const goBack = () => {
|
|||||||
</p>
|
</p>
|
||||||
<button
|
<button
|
||||||
class="inline-flex justify-center rounded-lg text-sm font-black py-2 mt-3 bg-text-primary text-background w-full"
|
class="inline-flex justify-center rounded-lg text-sm font-black py-2 mt-3 bg-text-primary text-background w-full"
|
||||||
@click="handleSubmit"
|
type="submit"
|
||||||
>
|
>
|
||||||
<span v-if="isRegister">Sign up</span>
|
<span v-if="isRegister">Sign up</span>
|
||||||
<span v-else>Log in / Sign up</span>
|
<span v-else>Log in / Sign up</span>
|
||||||
|
|||||||
@@ -10,8 +10,8 @@ export default session({
|
|||||||
rolling: true,
|
rolling: true,
|
||||||
cookie: {
|
cookie: {
|
||||||
httpOnly: true,
|
httpOnly: true,
|
||||||
secure: config.isProduction,
|
secure: false,
|
||||||
sameSite: 'strict',
|
sameSite: 'lax',
|
||||||
maxAge: config.sessionMaxAge,
|
maxAge: config.sessionMaxAge,
|
||||||
},
|
},
|
||||||
store: MongoStore.create({
|
store: MongoStore.create({
|
||||||
|
|||||||
Reference in new issue
Block a user