fix build error
All checks were successful
Build Docker Image / run (pull_request) Successful in 1m12s
All checks were successful
Build Docker Image / run (pull_request) Successful in 1m12s
This commit is contained in:
parent
19edb3472f
commit
ccb31a172d
@ -2,7 +2,7 @@
|
|||||||
import Layout from "../../layouts/Layout.astro";
|
import Layout from "../../layouts/Layout.astro";
|
||||||
import PocketBase from 'pocketbase';
|
import PocketBase from 'pocketbase';
|
||||||
import AstroUtils from "../../libs/AstroUtils";
|
import AstroUtils from "../../libs/AstroUtils";
|
||||||
import Schema from 'models/Schema'
|
// import Schema from 'models/Schema'
|
||||||
|
|
||||||
|
|
||||||
// const usr = await getUser(Astro.cookies)
|
// const usr = await getUser(Astro.cookies)
|
||||||
@ -17,8 +17,8 @@ const res = await AstroUtils.wrap(async () => {
|
|||||||
}
|
}
|
||||||
const form = await Astro.request.formData();
|
const form = await Astro.request.formData();
|
||||||
const request = {
|
const request = {
|
||||||
email: form.get("username") as String,
|
email: form.get("username") as string,
|
||||||
password: form.get("password") as String
|
password: form.get("password") as string,
|
||||||
}
|
}
|
||||||
const pb = new PocketBase('http://127.0.0.1:3001');
|
const pb = new PocketBase('http://127.0.0.1:3001');
|
||||||
|
|
||||||
@ -30,7 +30,9 @@ const res = await AstroUtils.wrap(async () => {
|
|||||||
// after the above you can also access the auth data from the authStore
|
// after the above you can also access the auth data from the authStore
|
||||||
console.log(pb.authStore.isValid);
|
console.log(pb.authStore.isValid);
|
||||||
console.log(pb.authStore.token);
|
console.log(pb.authStore.token);
|
||||||
console.log(pb.authStore.model.id);
|
if(pb.authStore.model){
|
||||||
|
console.log(pb.authStore.model.id);
|
||||||
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
---
|
---
|
||||||
|
Loading…
x
Reference in New Issue
Block a user