Fixed the cookie issue (i think)

This commit is contained in:
2025-03-02 22:06:30 +01:00
parent d8f97d0ee7
commit 62f4f4f35f
15 changed files with 184 additions and 163 deletions
+21 -11
View File
@@ -126,11 +126,16 @@ export default function PostDialog({
<Button
variant="secondary"
onClick={() => {
axios.post('/api/posts', {
sessionId,
platforms: ['andjksds'],
content,
} satisfies PostRequest);
axios.post(
'/api/posts',
{
platforms: ['andjksds'],
content,
} satisfies PostRequest,
{
withCredentials: true,
}
);
setNewPostDialogOpen(false);
}}
@@ -139,12 +144,17 @@ export default function PostDialog({
</Button>
<Button
onClick={async () => {
const { data } = await axios.put('/api/posts', {
scheduled: format(date, 'y-MM-dd hh:mm'),
sessionId,
platforms: ['andjksds'],
content,
} satisfies ScheduleRequest);
const { data } = await axios.put(
'/api/posts',
{
scheduled: format(date, 'y-MM-dd hh:mm'),
platforms: ['andjksds'],
content,
} satisfies ScheduleRequest,
{
withCredentials: true,
}
);
addEvent({
id: data.id,