Skip to content

Commit

Permalink
minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
OrJDev committed Dec 19, 2022
1 parent 67b010b commit 4885dae
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "create-jd-app",
"version": "1.0.104",
"version": "1.0.105",
"main": "dist/index.js",
"scripts": {
"test": "ts-node -r tsconfig-paths/register src",
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/utils/getIndexPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ import { authClient } from "~/utils/auth";`
: ""
}${
useNextAuth
? `\nimport { getSession } from "@solid-auth/next/session";\nimport { authOpts } from "./api/auth/[...solidauth]";\nimport { signIn, signOut } from "@solid-auth/next/client";`
? `\nimport { getSession } from "@solid-auth/next";\nimport { authOpts } from "./api/auth/[...solidauth]";\nimport { signIn, signOut } from "@solid-auth/next/client";`
: ""
}
${
Expand Down
6 changes: 6 additions & 0 deletions src/installers/NextAuth/files/prisma-handler.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ export const authOpts: SolidAuthConfig = {
clientSecret: serverEnv.GITHUB_SECRET,
}),
],
session: {
strategy: "database",
generateSessionToken: () => {
return crypto.randomUUID();
},
},
debug: false,
};

Expand Down
2 changes: 1 addition & 1 deletion src/installers/tRPC/utils/getTrpcContext.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import type { createSolidAPIHandlerContext } from "solid-start-trpc";${
usePrisma ? `\nimport { prisma } from "~/server/db/client";` : ""
}${useSolidAuth ? `\nimport { authenticator } from "../auth";` : ""}${
useNextAuth
? `\nimport { getSession } from "@solid-auth/next/session";\nimport { authOpts } from "~/routes/api/auth/[...solidauth]";`
? `\nimport { getSession } from "@solid-auth/next";\nimport { authOpts } from "~/routes/api/auth/[...solidauth]";`
: ""
}
Expand Down

0 comments on commit 4885dae

Please sign in to comment.