Allow options to override error

If an error was missing certain fields, they couldn't be provided by the opt parameter. This resolves that. It also checks showStack for actually being true, 'undefined' was filtering through.