fix: Use wp_signon for proper WordPress authentication in standalone login

This commit is contained in:
dwindown
2025-11-05 00:11:20 +07:00
parent 04e02f1d67
commit 15f0bcb4e4
4 changed files with 20 additions and 10 deletions

View File

@@ -9,7 +9,7 @@ export const api = {
if (!headers.has('Accept')) headers.set('Accept', 'application/json');
if (options.body && !headers.has('Content-Type')) headers.set('Content-Type', 'application/json');
const res = await fetch(url, { credentials: 'same-origin', ...options, headers });
const res = await fetch(url, { credentials: 'include', ...options, headers });
if (!res.ok) {
let responseData: any = null;