feat(exporter): handle docfield being non-nullable
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
This commit is contained in:
parent
8d540963c8
commit
8d91e4524f
1 changed files with 3 additions and 0 deletions
|
|
@ -162,6 +162,9 @@ class TypeExporter:
|
|||
if field.fieldtype in non_nullable_types:
|
||||
return False
|
||||
|
||||
if field.not_nullable:
|
||||
return False
|
||||
|
||||
return not bool(field.reqd)
|
||||
|
||||
def _generic_parameters(self, field) -> str | None:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue