prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  cannot delete user in django admin if user has not uploaded avatar 
  
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `euth/users/signals.py`
  Content:
  ```
  1 from django.db.models import signals
  2 from django.dispatch import receiver
  3 
  4 from adhocracy4.images import services
  5 
  6 from . import models
  7 
  8 
  9 @receiver(signals.post_init, sender=models.User)
  10 def backup_image_path(sender, instance, **kwargs):
  11     instance._current_image_file = instance.avatar
  12 
  13 
  14 @receiver(signals.post_save, sender=models.User)
  15 def delete_old_image(sender, instance, **kwargs):
  16     if hasattr(instance, '_current_image_file'):
  17         if instance._current_image_file != instance.avatar:
  18             services.delete_images([instance._current_image_file])
  19 
  20 
  21 @receiver(signals.post_delete, sender=models.User)
  22 def delete_images_for_User(sender, instance, **kwargs):
  23     services.delete_images([instance.avatar])
  24
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/euth/users/signals.py b/euth/users/signals.py
  --- a/euth/users/signals.py
  +++ b/euth/users/signals.py
  @@ -20,4 +20,4 @@
   
   @receiver(signals.post_delete, sender=models.User)
   def delete_images_for_User(sender, instance, **kwargs):
  -    services.delete_images([instance.avatar])
  +    services.delete_images([instance._avatar])
  
verification_info: {"golden_diff": "diff --git a/euth/users/signals.py b/euth/users/signals.py\n--- a/euth/users/signals.py\n+++ b/euth/users/signals.py\n@@ -20,4 +20,4 @@\n \n @receiver(signals.post_delete, sender=models.User)\n def delete_images_for_User(sender, instance, **kwargs):\n-    services.delete_images([instance.avatar])\n+    services.delete_images([instance._avatar])\n", "issue": "cannot delete user in django admin if user has not uploaded avatar \n\n", "before_files": [{"content": "from django.db.models import signals\nfrom django.dispatch import receiver\n\nfrom adhocracy4.images import services\n\nfrom . import models\n\n\n@receiver(signals.post_init, sender=models.User)\ndef backup_image_path(sender, instance, **kwargs):\n    instance._current_image_file = instance.avatar\n\n\n@receiver(signals.post_save, sender=models.User)\ndef delete_old_image(sender, instance, **kwargs):\n    if hasattr(instance, '_current_image_file'):\n        if instance._current_image_file != instance.avatar:\n            services.delete_images([instance._current_image_file])\n\n\n@receiver(signals.post_delete, sender=models.User)\ndef delete_images_for_User(sender, instance, **kwargs):\n    services.delete_images([instance.avatar])\n", "path": "euth/users/signals.py"}], "after_files": [{"content": "from django.db.models import signals\nfrom django.dispatch import receiver\n\nfrom adhocracy4.images import services\n\nfrom . import models\n\n\n@receiver(signals.post_init, sender=models.User)\ndef backup_image_path(sender, instance, **kwargs):\n    instance._current_image_file = instance.avatar\n\n\n@receiver(signals.post_save, sender=models.User)\ndef delete_old_image(sender, instance, **kwargs):\n    if hasattr(instance, '_current_image_file'):\n        if instance._current_image_file != instance.avatar:\n            services.delete_images([instance._current_image_file])\n\n\n@receiver(signals.post_delete, sender=models.User)\ndef delete_images_for_User(sender, instance, **kwargs):\n    services.delete_images([instance._avatar])\n", "path": "euth/users/signals.py"}]}