Changing the way the error module is called.

Instead of calling it with the error as the scope, it is now called with
the error as a parameter, which is more intuitive.
No longer reading the URL parameter if the config specifies a main module.