diff options
Diffstat (limited to 'ishtar_common/models.py')
-rw-r--r-- | ishtar_common/models.py | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py index 394bd5382..48ed55e77 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -577,29 +577,6 @@ class ImageModel(models.Model, ImageContainerModel): return "{}-thumb.{}".format(".".join(splited[:-1]), splited[-1]) -class BulkUpdatedItem(object): - @classmethod - def bulk_recursion(cls, transaction_id, extra_args): - """ - Prevent infinite recursion. Should not happen but wrong manipulation - in the database or messy imports can generate circular relations - - :param transaction_id: current transaction ID (unix time) - if null - a transaction ID is generated - :param extra_args: arguments dealing with - :return: (transaction ID, is a recursion) - """ - # TODO: no more bulk update - should be removed - if not transaction_id: - transaction_id = str(time.time()) - args = ["cached_label_bulk_update", transaction_id] + extra_args - key, val = get_cache(cls, args) - if val: - return transaction_id, True - cache.set(key, 1, settings.CACHE_SMALLTIMEOUT) - return transaction_id, False - - class RelationItem(models.Model): """ Items with relation between them |