Fixing an issue with creating a cache directory