mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-19 01:35:18 -04:00
Add explicit type annotations to nullable columns
TypeORM can't correctly infer the data type on properties with a `| null` type. This commit adds explicit type annotations. See also https://github.com/typeorm/typeorm/issues/2567#issuecomment-408599335 Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
f9a0353748
commit
d1e352d56c
5 changed files with 11 additions and 0 deletions
|
@ -35,6 +35,7 @@ export class Note {
|
|||
@Column({
|
||||
unique: true,
|
||||
nullable: true,
|
||||
type: 'text',
|
||||
})
|
||||
alias: string | null;
|
||||
@OneToMany(
|
||||
|
@ -70,10 +71,12 @@ export class Note {
|
|||
|
||||
@Column({
|
||||
nullable: true,
|
||||
type: 'text',
|
||||
})
|
||||
description: string | null;
|
||||
@Column({
|
||||
nullable: true,
|
||||
type: 'text',
|
||||
})
|
||||
title: string | null;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue