Placed thread insertion to the repository. Improved incrementHits function.