fixed issue with parent dir not created