Implement History
Remove console.log for debug