fix statistics calculation (async calls and so on)