fix loadDir() when no dirName hook is present