bugfix: Allow notification only for Model subclasses
This commit is contained in:
		@ -54,7 +54,7 @@ class Subscription(Model):
 | 
			
		||||
# --- SUBSCRIPTION SYSTEM ---
 | 
			
		||||
@receiver(post_save, dispatch_uid="callback_notif")
 | 
			
		||||
def send_notification(sender, instance, **kwargs):
 | 
			
		||||
    if (sender != Notification and sender != LogEntry and sender != Session and sender != Token):
 | 
			
		||||
    if sender != Notification and isinstance(sender, Model):
 | 
			
		||||
        threads = []
 | 
			
		||||
        url = settings.BASE_URL + Model.resource_id(instance) + '/'
 | 
			
		||||
        for subscription in Subscription.objects.filter(object=url):
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user