prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Cannot place order in saleor demo's storefront
  ### What I'm trying to achieve
  Place an order on the demo store to reproduce another bug. :wink:
  
  ### Steps to reproduce the problem
  1. Create a cart with an item;
  2. Follow the checkout until the summary page;
  3. Try to hit "Order & Pay";
  4. A server error should occur.
  
  **System information**
  ```
  Host: demo.getsaleor.com
  User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Firefox/60.0
  Accept-Language: en,en-GB;q=0.8,en-US
  Accept-Encoding: gzip, deflate, br
  Referer: https://demo.getsaleor.com/en/checkout/summary/
  ```
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `saleor/account/utils.py`
  Content:
  ```
  1 from ..checkout import AddressType
  2 from ..core.demo_obfuscators import obfuscate_address
  3 
  4 
  5 def store_user_address(user, address, address_type):
  6     """Add address to user address book and set as default one."""
  7     address, _ = user.addresses.get_or_create(**address.as_data())
  8 
  9     # DEMO: obfuscate user address
  10     address = obfuscate_address(address)
  11 
  12     if address_type == AddressType.BILLING:
  13         if not user.default_billing_address:
  14             user.default_billing_address = address
  15             user.save(update_fields=['default_billing_address'])
  16     elif address_type == AddressType.SHIPPING:
  17         if not user.default_shipping_address:
  18             user.default_shipping_address = address
  19             user.save(update_fields=['default_shipping_address'])
  20
  ```
  --- 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/saleor/account/utils.py b/saleor/account/utils.py
  --- a/saleor/account/utils.py
  +++ b/saleor/account/utils.py
  @@ -4,11 +4,11 @@
   
   def store_user_address(user, address, address_type):
       """Add address to user address book and set as default one."""
  -    address, _ = user.addresses.get_or_create(**address.as_data())
  -
       # DEMO: obfuscate user address
       address = obfuscate_address(address)
   
  +    address, _ = user.addresses.get_or_create(**address.as_data())
  +
       if address_type == AddressType.BILLING:
           if not user.default_billing_address:
               user.default_billing_address = address
  
verification_info: {"golden_diff": "diff --git a/saleor/account/utils.py b/saleor/account/utils.py\n--- a/saleor/account/utils.py\n+++ b/saleor/account/utils.py\n@@ -4,11 +4,11 @@\n \n def store_user_address(user, address, address_type):\n     \"\"\"Add address to user address book and set as default one.\"\"\"\n-    address, _ = user.addresses.get_or_create(**address.as_data())\n-\n     # DEMO: obfuscate user address\n     address = obfuscate_address(address)\n \n+    address, _ = user.addresses.get_or_create(**address.as_data())\n+\n     if address_type == AddressType.BILLING:\n         if not user.default_billing_address:\n             user.default_billing_address = address\n", "issue": "Cannot place order in saleor demo's storefront\n### What I'm trying to achieve\r\nPlace an order on the demo store to reproduce another bug. :wink:\r\n\r\n### Steps to reproduce the problem\r\n1. Create a cart with an item;\r\n2. Follow the checkout until the summary page;\r\n3. Try to hit \"Order & Pay\";\r\n4. A server error should occur.\r\n\r\n**System information**\r\n```\r\nHost: demo.getsaleor.com\r\nUser-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Firefox/60.0\r\nAccept-Language: en,en-GB;q=0.8,en-US\r\nAccept-Encoding: gzip, deflate, br\r\nReferer: https://demo.getsaleor.com/en/checkout/summary/\r\n```\n", "before_files": [{"content": "from ..checkout import AddressType\nfrom ..core.demo_obfuscators import obfuscate_address\n\n\ndef store_user_address(user, address, address_type):\n    \"\"\"Add address to user address book and set as default one.\"\"\"\n    address, _ = user.addresses.get_or_create(**address.as_data())\n\n    # DEMO: obfuscate user address\n    address = obfuscate_address(address)\n\n    if address_type == AddressType.BILLING:\n        if not user.default_billing_address:\n            user.default_billing_address = address\n            user.save(update_fields=['default_billing_address'])\n    elif address_type == AddressType.SHIPPING:\n        if not user.default_shipping_address:\n            user.default_shipping_address = address\n            user.save(update_fields=['default_shipping_address'])\n", "path": "saleor/account/utils.py"}], "after_files": [{"content": "from ..checkout import AddressType\nfrom ..core.demo_obfuscators import obfuscate_address\n\n\ndef store_user_address(user, address, address_type):\n    \"\"\"Add address to user address book and set as default one.\"\"\"\n    # DEMO: obfuscate user address\n    address = obfuscate_address(address)\n\n    address, _ = user.addresses.get_or_create(**address.as_data())\n\n    if address_type == AddressType.BILLING:\n        if not user.default_billing_address:\n            user.default_billing_address = address\n            user.save(update_fields=['default_billing_address'])\n    elif address_type == AddressType.SHIPPING:\n        if not user.default_shipping_address:\n            user.default_shipping_address = address\n            user.save(update_fields=['default_shipping_address'])\n", "path": "saleor/account/utils.py"}]}