I believe https://github.com/gothinkster/elixir-phoenix-realworld-example-app/blob/master/lib/real_world_web/controllers/user_controller.ex#L29-L35 is redundant and confusing. There is no need to check `user` for nil and render 404.json, as Guardian already has an error handler which will be invoked when trying to access `UserController#current_user` without being authenticated.
I believe https://github.com/gothinkster/elixir-phoenix-realworld-example-app/blob/master/lib/real_world_web/controllers/user_controller.ex#L29-L35 is redundant and confusing. There is no need to check
userfor nil and render 404.json, as Guardian already has an error handler which will be invoked when trying to accessUserController#current_userwithout being authenticated.