diff --git a/sapl/base/receivers.py b/sapl/base/receivers.py index 3c6e6fc6a..a33edeee0 100644 --- a/sapl/base/receivers.py +++ b/sapl/base/receivers.py @@ -29,12 +29,12 @@ def handle_tramitacao_signal(sender, **kwargs): @receiver(post_delete) def status_tramitacao_materia(sender, instance, **kwargs): - if isinstance(sender, Tramitacao): + if sender == Tramitacao: if instance.status.indicador == 'F': materia = instance.materia materia.em_tramitacao = True materia.save() - elif isinstance(sender, TramitacaoAdministrativo): + elif sender == TramitacaoAdministrativo: if instance.status.indicador == 'F': documento = instance.documento documento.tramitacao = True