diff --git a/config/shield.ts b/config/shield.ts index a7b794c..d3aa290 100644 --- a/config/shield.ts +++ b/config/shield.ts @@ -16,9 +16,9 @@ const shieldConfig = defineConfig({ * to learn more */ csrf: { - enabled: false, + enabled: true, exceptRoutes: [], - enableXsrfCookie: false, + enableXsrfCookie: true, methods: ['POST', 'PUT', 'PATCH', 'DELETE'], }, diff --git a/inertia/components/posts/feed_list.tsx b/inertia/components/posts/feed_list.tsx index 9ef3b12..ccc6006 100644 --- a/inertia/components/posts/feed_list.tsx +++ b/inertia/components/posts/feed_list.tsx @@ -59,7 +59,7 @@ export default function FeedList({ ) : ( allPosts?.map((post, index) => ( - + )) )}
diff --git a/inertia/pages/feed.tsx b/inertia/pages/feed.tsx index 04f797d..775828e 100644 --- a/inertia/pages/feed.tsx +++ b/inertia/pages/feed.tsx @@ -10,9 +10,11 @@ export default function Feed({ posts, user }: InferPageProps -
- -
+ {user && ( +
+ +
+ )} ) }