Update util.js

The change allows for having routes files within subdirectories and eliminating error:
TypeError: undefined is not a function
due to "callback" being undefined

Example:
```
routes
  api
    endpoint1.js
    endpoint2.js
  site
    index.js
    base.js
    user.js
  config
    routes.js
```