Added validation for mkdir