Revert "Fix the dir module."

This reverts commit 4b0ee2e7ca904d150a687435c2e1b0fdbc241572.

Sorry, bad idea.