diff --git a/src/caosdb/connection/connection.py b/src/caosdb/connection/connection.py
index d21f8b0c65ca8be5a9ccb687542ee838a50b2d79..f818d6a05cdd1fb9019d56e63ba3b5f4947b823b 100644
--- a/src/caosdb/connection/connection.py
+++ b/src/caosdb/connection/connection.py
@@ -604,7 +604,7 @@ class _Connection(object):  # pylint: disable=useless-object-inheritance
             body=body, **kwargs)
         _LOGGER.debug("response: %s %s", str(http_response.status),
                       str(http_response.getheaders()))
-        _handle_response_status(http_response)
         self._authenticator.on_response(http_response)
+        _handle_response_status(http_response)
 
         return http_response