Fix ordering. auth.loginrequired decorator does not work when it comes before jsonrpc.method.
Fix bug where a 401 response would result in a stack trace.