dir -> directory [ci skip]
Merge pull request #10463 from prathamesh-sonpatki/dir

dir -> directory [ci skip]
Changing method call according to rails coding conventions