Extract methods "getCurrentUser" and "getCurrentUser" to ApiController.