Check path for being a dir, rather than just fo existence

This way, if path is not dir, sensible error will be raised during attempt to create dirs on logger initialization/attempt to write cache