fixed: 401 response in some cases