Base: Fix error handling on unauthorized requests