chore: Update django api
Part-of: <https://dev.funkwhale.audio/funkwhale/funkwhale/-/merge_requests/2709>
This commit is contained in:
parent
5252c29fa7
commit
fbc4c32657
|
@ -60,12 +60,12 @@ class NullsLastSQLCompiler(SQLCompiler):
|
|||
class NullsLastQuery(models.sql.query.Query):
|
||||
"""Use a custom compiler to inject 'NULLS LAST' (for PostgreSQL)."""
|
||||
|
||||
def get_compiler(self, using=None, connection=None):
|
||||
def get_compiler(self, using=None, connection=None, elide_empty=True):
|
||||
if using is None and connection is None:
|
||||
raise ValueError("Need either using or connection")
|
||||
if using:
|
||||
connection = connections[using]
|
||||
return NullsLastSQLCompiler(self, connection, using)
|
||||
return NullsLastSQLCompiler(self, connection, using, elide_empty)
|
||||
|
||||
|
||||
class NullsLastQuerySet(models.QuerySet):
|
||||
|
|
Loading…
Reference in New Issue