Some useless function calls removed.
require_direcory and require_tree implemented.