Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 27e95846 authored by Adam Tauber's avatar Adam Tauber
Browse files

[fix] measure request duration only if total_time attribute is set - fixes autocompleter

parent 060c7977
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -122,7 +122,7 @@ def request(method, url, **kwargs):
    # session end
    session.close()

    #
    if hasattr(threadLocal, 'total_time'):
        threadLocal.total_time += time_after_request - time_before_request

    return response