@@ -114,7 +114,7 @@ def update(self, **fields):
114
114
# affected, let's do the same
115
115
return len (rows )
116
116
117
- def on_conflict (self , fields : List [Union [str , Tuple [str ]]], action , index_predicate = None ):
117
+ def on_conflict (self , fields : List [Union [str , Tuple [str ]]], action , index_predicate : str = None ):
118
118
"""Sets the action to take when conflicts arise when attempting
119
119
to insert/create a new row.
120
120
@@ -223,7 +223,7 @@ def insert_and_get(self, **fields):
223
223
224
224
return self .model (** model_init_fields )
225
225
226
- def upsert (self , conflict_target : List , fields : Dict , index_predicate = None ) -> int :
226
+ def upsert (self , conflict_target : List , fields : Dict , index_predicate : str = None ) -> int :
227
227
"""Creates a new record or updates the existing one
228
228
with the specified data.
229
229
@@ -478,7 +478,7 @@ def on_conflict(self, fields: List[Union[str, Tuple[str]]], action):
478
478
"""
479
479
return self .get_queryset ().on_conflict (fields , action )
480
480
481
- def upsert (self , conflict_target : List , fields : Dict , index_predicate = None ) -> int :
481
+ def upsert (self , conflict_target : List , fields : Dict , index_predicate : str = None ) -> int :
482
482
"""Creates a new record or updates the existing one
483
483
with the specified data.
484
484
0 commit comments