Fixing caching problems

Seems like I missed a few things with the last commit. Local and
staging / prod should build correctly wrt the cache being used.
Merge branch 'cache_enhancement'