Skip to content

Commit

Permalink
fix: convert None to a string null for the is method (#446)
Browse files Browse the repository at this point in the history
  • Loading branch information
silentworks committed Jun 1, 2024
1 parent 901108a commit 9970ac3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions postgrest/base_request_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,8 @@ def is_(self: Self, column: str, value: Any) -> Self:
column: The name of the column to apply a filter on
value: The value to filter by
"""
if value is None:
value = "null"
return self.filter(column, Filters.IS, value)

def like(self: Self, column: str, pattern: str) -> Self:
Expand Down

0 comments on commit 9970ac3

Please sign in to comment.