mirror of
https://github.com/Dan6erbond/sk-auth.git
synced 2025-04-23 01:16:26 +02:00
Fix breaking changes
This commit is contained in:
parent
19bff9a39c
commit
ed66d383b1
@ -1,17 +1,3 @@
|
||||
import type { Handle } from "@sveltejs/kit";
|
||||
import { appAuth } from "$lib/appAuth";
|
||||
|
||||
export const handle: Handle = async ({ event, resolve }) => {
|
||||
// TODO https://github.com/sveltejs/kit/issues/1046
|
||||
|
||||
|
||||
if (event.request.query.has("_method")) {
|
||||
event.request.method = event.request.query.get("_method").toUpperCase();
|
||||
}
|
||||
|
||||
const response = await resolve(event);
|
||||
|
||||
return response;
|
||||
};
|
||||
|
||||
export const { getSession } = appAuth;
|
||||
|
@ -47,7 +47,7 @@
|
||||
"rounded-full",
|
||||
)}
|
||||
>
|
||||
{#if $page.path === "/profile"}
|
||||
{#if $page.url.pathname === "/profile"}
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class={clsx("h-6", "w-6")}
|
||||
@ -118,7 +118,7 @@
|
||||
"p-2",
|
||||
"rounded-full",
|
||||
)}
|
||||
class:text-orange-500={$page.path === "/login"}
|
||||
class:text-orange-500={$page.url.pathname === "/login"}
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
|
@ -9,11 +9,6 @@ const config = {
|
||||
postcss: true,
|
||||
}),
|
||||
],
|
||||
|
||||
kit: {
|
||||
// hydrate the <div id="svelte"> element in src/app.html
|
||||
target: "#svelte",
|
||||
},
|
||||
};
|
||||
|
||||
export default config;
|
||||
|
@ -1,6 +1,5 @@
|
||||
import type { GetSession, RequestHandler } from "@sveltejs/kit";
|
||||
import type { EndpointOutput } from "@sveltejs/kit/types/endpoint";
|
||||
import { RequestEvent } from "@sveltejs/kit/types/hooks";
|
||||
import type { EndpointOutput, RequestEvent } from "@sveltejs/kit";
|
||||
import cookie from "cookie";
|
||||
import * as jsonwebtoken from "jsonwebtoken";
|
||||
import type { JWT, Session } from "./interfaces";
|
||||
|
@ -1,5 +1,4 @@
|
||||
import type { EndpointOutput } from "@sveltejs/kit";
|
||||
import { RequestEvent } from "@sveltejs/kit/types/hooks";
|
||||
import type { EndpointOutput, RequestEvent } from "@sveltejs/kit";
|
||||
import type { Auth } from "../auth";
|
||||
import type { CallbackResult } from "../types";
|
||||
|
||||
|
@ -1,5 +1,4 @@
|
||||
import type { EndpointOutput } from "@sveltejs/kit/types/endpoint";
|
||||
import { RequestEvent } from "@sveltejs/kit/types/hooks";
|
||||
import type { EndpointOutput, RequestEvent } from "@sveltejs/kit";
|
||||
import type { Auth } from "../auth";
|
||||
import type { CallbackResult } from "../types";
|
||||
import { Provider, ProviderConfig } from "./base";
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { RequestEvent } from "@sveltejs/kit/types/hooks";
|
||||
import { RequestEvent } from "@sveltejs/kit";
|
||||
import type { Auth } from "../auth";
|
||||
import { ucFirst } from "../helpers";
|
||||
import { OAuth2BaseProvider, OAuth2BaseProviderConfig, OAuth2Tokens } from "./oauth2.base";
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { RequestEvent } from "@sveltejs/kit/types/hooks";
|
||||
import { RequestEvent } from "@sveltejs/kit";
|
||||
import type { Auth } from "../auth";
|
||||
import { OAuth2BaseProvider, OAuth2BaseProviderConfig } from "./oauth2.base";
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user