added fucntionalty to history