fixed issue with creating directory