Skip to content

Commit

Permalink
fix refers
Browse files Browse the repository at this point in the history
  • Loading branch information
jsbroks committed Nov 16, 2024
1 parent 45f1cfb commit 26acfd8
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 11 deletions.
6 changes: 5 additions & 1 deletion packages/auth/eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
import baseConfig, { restrictEnvAccess } from "@ctrlplane/eslint-config/base";
import baseConfig, {
requireJsSuffix,
restrictEnvAccess,
} from "@ctrlplane/eslint-config/base";

/** @type {import('typescript-eslint').Config} */
export default [
{
ignores: ["dist/**", "node_modules/**"],
},
...baseConfig,
...requireJsSuffix,
...restrictEnvAccess,
];
4 changes: 2 additions & 2 deletions packages/auth/src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ import { db } from "@ctrlplane/db/client";
import * as schema from "@ctrlplane/db/schema";
import { signInSchema } from "@ctrlplane/validators/auth";

import { env } from "./env";
import { getUserByCredentials } from "./utils/credentials";
import { env } from "./env.js";
import { getUserByCredentials } from "./utils/credentials.js";

declare module "next-auth" {
interface Session {
Expand Down
4 changes: 2 additions & 2 deletions packages/auth/src/index.rsc.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { cache } from "react";
import NextAuth from "next-auth";

import { authConfig } from "./config";
import { authConfig } from "./config.js";

export * from "./config";
export * from "./config.js";
export type { Session } from "next-auth";

const {
Expand Down
4 changes: 2 additions & 2 deletions packages/auth/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import NextAuth from "next-auth";

import { authConfig } from "./config";
import { authConfig } from "./config.js";

export * from "./config";
export * from "./config.js";
export type { Session } from "next-auth";

const {
Expand Down
2 changes: 1 addition & 1 deletion packages/auth/src/utils/can.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { EntityType, ScopeType } from "@ctrlplane/db/schema";

import { checkEntityPermissionForResource } from "./rbac";
import { checkEntityPermissionForResource } from "./rbac.js";

// New type definition
export type CanFunction = {
Expand Down
6 changes: 3 additions & 3 deletions packages/auth/src/utils/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
export * from "./api-key";
export * from "./rbac";
export * from "./can";
export * from "./api-key.js";
export * from "./rbac.js";
export * from "./can.js";

0 comments on commit 26acfd8

Please sign in to comment.