Added directory creation.