add the IsDir check back in walker func