In panicOnError, log err, pass message

Instead of immediately logging the message and then passing on the error
stack, immediately log the error stack (which isn't very "friendly", but
could be very useful in our logs) and pass on the specified message
(which should be more human-oriented, such that it could make its way
out as an explanation of what went wrong in the user interface after
catching the panic (or not cataching the panic, as the case may be).