Fixed bug by adding ref to cache key
Simplify last commit
Merge pull request #35 from rudyrigot/cache_ref_bug

Fixed bug by adding ref to cache key