Added in the function cacheThis to the resource controller.