-
Notifications
You must be signed in to change notification settings - Fork 51
Closed
Labels
bug/2-confirmedBug has been reproduced and confirmed.Bug has been reproduced and confirmed.kind/bugA reported bug.A reported bug.
Milestone
Description
Bug description
Renaming a single model doesn't rename all the instances of that model where it's present in the same relation.
How to reproduce
- Create a model:
model User {
id Int @id @default(autoincrement())
favoriteArticles Article[] @relation("FavoritedArticles")
writtenArticles Article[]
}
model Article {
id Int @id @default(autoincrement())
slug String @unique
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
title String
description String
markdownContent String
user User @relation(fields: [userId], references: [id])
tags ArticleTag[]
favoritedBy User[] @relation("FavoritedArticles")
userId Int
}
model ArticleTag {
name String @id
articles Article[]
}- Rename the
Articlemodel
- This is the output
Expected behavior
All instances of the model should be renamed.
Environment & setup
- OS: Mac OS
- Editor: VSCode
- Editor version: 1.51.1
- Extension version: 2.12.1
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bug/2-confirmedBug has been reproduced and confirmed.Bug has been reproduced and confirmed.kind/bugA reported bug.A reported bug.

