fixes bug during creation of a new folder.