Moved variables to cache and config