mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-11-25 19:26:31 -05:00
docs: clarify comments for orphanedRowAction
Co-authored-by: Yannick Bungers <git@innay.de> Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
a626ace4b9
commit
4188b21685
3 changed files with 6 additions and 6 deletions
|
@ -23,13 +23,13 @@ export class HistoryEntry {
|
|||
|
||||
@ManyToOne((_) => User, (user) => user.historyEntries, {
|
||||
onDelete: 'CASCADE',
|
||||
orphanedRowAction: 'delete', // This ensures the whole row is deleted when the Entry stops being referenced
|
||||
orphanedRowAction: 'delete', // This ensures the row of the history entry is deleted when no user references it anymore
|
||||
})
|
||||
user: Promise<User>;
|
||||
|
||||
@ManyToOne((_) => Note, (note) => note.historyEntries, {
|
||||
onDelete: 'CASCADE',
|
||||
orphanedRowAction: 'delete', // This ensures the whole row is deleted when the Entry stops being referenced
|
||||
orphanedRowAction: 'delete', // This ensures the row of the history entry is deleted when no note references it anymore
|
||||
})
|
||||
note: Promise<Note>;
|
||||
|
||||
|
|
|
@ -22,13 +22,13 @@ export class NoteGroupPermission {
|
|||
|
||||
@ManyToOne((_) => Group, {
|
||||
onDelete: 'CASCADE', // This deletes the NoteGroupPermission, when the associated Group is deleted
|
||||
orphanedRowAction: 'delete', // This ensures the whole row is deleted when the Permission stops being referenced
|
||||
orphanedRowAction: 'delete', // This ensures the row of the NoteGroupPermission is deleted when no group references it anymore
|
||||
})
|
||||
group: Promise<Group>;
|
||||
|
||||
@ManyToOne((_) => Note, (note) => note.groupPermissions, {
|
||||
onDelete: 'CASCADE', // This deletes the NoteGroupPermission, when the associated Note is deleted
|
||||
orphanedRowAction: 'delete', // This ensures the whole row is deleted when the Permission stops being referenced
|
||||
orphanedRowAction: 'delete', // This ensures the row of the NoteGroupPermission is deleted when no note references it anymore
|
||||
})
|
||||
note: Promise<Note>;
|
||||
|
||||
|
|
|
@ -22,13 +22,13 @@ export class NoteUserPermission {
|
|||
|
||||
@ManyToOne((_) => User, {
|
||||
onDelete: 'CASCADE', // This deletes the NoteUserPermission, when the associated Note is deleted
|
||||
orphanedRowAction: 'delete', // This ensures the whole row is deleted when the Permission stops being referenced
|
||||
orphanedRowAction: 'delete', // This ensures the row of the NoteUserPermission is deleted when no user references it anymore
|
||||
})
|
||||
user: Promise<User>;
|
||||
|
||||
@ManyToOne((_) => Note, (note) => note.userPermissions, {
|
||||
onDelete: 'CASCADE', // This deletes the NoteUserPermission, when the associated Note is deleted
|
||||
orphanedRowAction: 'delete', // This ensures the whole row is deleted when the Permission stops being referenced
|
||||
orphanedRowAction: 'delete', // This ensures the row of the NoteUserPermission is deleted when no note references it anymore
|
||||
})
|
||||
note: Promise<Note>;
|
||||
|
||||
|
|
Loading…
Reference in a new issue