Skip to content

Commit 4c9b2b1

Browse files
authored
Update prisma to v5.12.0 (#687)
1 parent 78ef252 commit 4c9b2b1

File tree

3 files changed

+22
-19
lines changed

3 files changed

+22
-19
lines changed

package-lock.json

Lines changed: 16 additions & 16 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
"@epic-web/totp": "^1.1.2",
5050
"@nasa-gcn/remix-seo": "^2.0.0",
5151
"@paralleldrive/cuid2": "^2.2.2",
52-
"@prisma/client": "^5.11.0",
52+
"@prisma/client": "^5.12.0",
5353
"@radix-ui/react-checkbox": "^1.0.4",
5454
"@radix-ui/react-dropdown-menu": "^2.0.6",
5555
"@radix-ui/react-label": "^2.0.2",
@@ -88,7 +88,7 @@
8888
"litefs-js": "^1.1.2",
8989
"lru-cache": "^10.2.0",
9090
"morgan": "^1.10.0",
91-
"prisma": "^5.11.0",
91+
"prisma": "^5.12.0",
9292
"qrcode": "^1.5.3",
9393
"react": "^18.2.0",
9494
"react-dom": "^18.2.0",

prisma/seed.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,16 @@ async function seed() {
2323
const entities = ['user', 'note']
2424
const actions = ['create', 'read', 'update', 'delete']
2525
const accesses = ['own', 'any'] as const
26+
27+
let permissionsToCreate = []
2628
for (const entity of entities) {
2729
for (const action of actions) {
2830
for (const access of accesses) {
29-
await prisma.permission.create({ data: { entity, action, access } })
31+
permissionsToCreate.push({ entity, action, access })
3032
}
3133
}
3234
}
35+
await prisma.permission.createMany({ data: permissionsToCreate })
3336
console.timeEnd('🔑 Created permissions...')
3437

3538
console.time('👑 Created roles...')

0 commit comments

Comments
 (0)