WhatsApp/Signal/Formstack/admin updates
This commit is contained in:
parent
bcecf61a46
commit
d0cc5a21de
451 changed files with 16139 additions and 39623 deletions
|
|
@ -2,12 +2,11 @@ import { getServerSession } from "app/_lib/authentication";
|
|||
import { cookies } from "next/headers";
|
||||
|
||||
const getHeaders = async () => {
|
||||
const allCookies = cookies().getAll();
|
||||
const allCookies = (await cookies()).getAll();
|
||||
const session = await getServerSession();
|
||||
const headers = {
|
||||
const finalHeaders = {
|
||||
"Content-Type": "application/json",
|
||||
Accept: "application/json",
|
||||
"X-Browser-Fingerprint": `${session.expires}`,
|
||||
// @ts-ignore
|
||||
"X-CSRF-Token": session.user.zammadCsrfToken,
|
||||
Cookie: allCookies
|
||||
|
|
@ -15,7 +14,7 @@ const getHeaders = async () => {
|
|||
.join("; "),
|
||||
};
|
||||
|
||||
return headers;
|
||||
return finalHeaders;
|
||||
};
|
||||
|
||||
interface ExecuteGraphQLOptions {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue