implemented History Functionality