File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
packages/runtime/src/client/crud/operations Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -1488,6 +1488,9 @@ export abstract class BaseOperationHandler<Schema extends SchemaDef> {
14881488 const results : ( unknown | undefined ) [ ] = [ ] ;
14891489 for ( const d of _data ) {
14901490 const ids = await this . getEntityIds ( kysely , model , d ) ;
1491+ if ( ! ids ) {
1492+ throw new NotFoundError ( model ) ;
1493+ }
14911494 const r = await this . handleManyToManyRelation (
14921495 kysely ,
14931496 'connect' ,
@@ -1732,6 +1735,9 @@ export abstract class BaseOperationHandler<Schema extends SchemaDef> {
17321735 const results : ( unknown | undefined ) [ ] = [ ] ;
17331736 for ( const d of _data ) {
17341737 const ids = await this . getEntityIds ( kysely , model , d ) ;
1738+ if ( ! ids ) {
1739+ throw new NotFoundError ( model ) ;
1740+ }
17351741 results . push (
17361742 await this . handleManyToManyRelation (
17371743 kysely ,
You can’t perform that action at this time.
0 commit comments