Add headers for cache image
Removing unused variables and methods
Fixing merge by upstream
Porcaria