Skip to content

Commit

Permalink
deps(server): Update to Mongoose 8
Browse files Browse the repository at this point in the history
  • Loading branch information
nellh committed Jan 27, 2025
1 parent cc05ffb commit e33c9fa
Show file tree
Hide file tree
Showing 7 changed files with 231 additions and 2,033 deletions.
1,177 changes: 123 additions & 1,054 deletions .pnp.cjs

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@
"jsdom": "24.0.0",
"lerna": "3.20.2",
"lint-staged": "^10.5.4",
"mongoose": "6.13.5",
"pinst": "^2.1.6",
"prettier": "^2.2.1",
"react": "18.2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/openneuro-server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"keyv": "^4.5.3",
"mime-types": "^2.1.19",
"mongodb-memory-server": "^9.2.0",
"mongoose": "6.13.5",
"mongoose": "^8.9.5",
"morgan": "^1.6.1",
"node-mailjet": "^3.3.5",
"object-hash": "2.1.1",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export async function permissions(ds): Promise<DatasetPermission> {
(userPermission) => ({
...userPermission.toJSON(),
user: user(ds, { id: userPermission.userId }),
} as PermissionDocument & { user: Promise<UserDocument> }),
} as unknown as PermissionDocument & { user: Promise<UserDocument> }),

Check warning on line 21 in packages/openneuro-server/src/graphql/resolvers/permissions.ts

View check run for this annotation

Codecov / codecov/patch

packages/openneuro-server/src/graphql/resolvers/permissions.ts#L21

Added line #L21 was not covered by tests
),
}
}
Expand Down
1 change: 1 addition & 0 deletions packages/openneuro-server/src/models/subscription.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import type { Document } from "mongoose"
const { Schema, model } = mongoose

export interface SubscriptionDocument extends Document {
_id: string
datasetId: string
userId: string
}
Expand Down
1 change: 1 addition & 0 deletions packages/openneuro-server/src/models/user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import type { Document } from "mongoose"
const { Schema, model } = mongoose

export interface UserDocument extends Document {
_id: string
id: string
email: string
name: string
Expand Down
Loading

0 comments on commit e33c9fa

Please sign in to comment.