Skip to content

Commit

Permalink
Revert "Allow to clear field"
Browse files Browse the repository at this point in the history
This reverts commit a50a963.
  • Loading branch information
Aadesh-Baral committed Jul 27, 2022
1 parent 55526be commit 413309b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/models/postgis/user.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def update(self, user_dto: UserDTO):

try:
is_field_nullable = self.__table__.columns[attr].nullable
if is_field_nullable:
if is_field_nullable and value is not None:
setattr(self, attr, value)
elif value is not None:
setattr(self, attr, value)
Expand Down

0 comments on commit 413309b

Please sign in to comment.