Added a cache feature (user won't lose value while scrolling through history).