fix cache directory initialization