Added history fetching.