Skip to content

Commit

Permalink
Adding image to user %Info (#34)
Browse files Browse the repository at this point in the history
Pretty much all other Ueberauth strategies use image: for purposes of the user avatar. I suggest doing this same with the GitHub strategy, so as to avoid needing to customize the templating for this strategy.

As an example see: these other strategies

LINE 111 in https://github.com/ueberauth/ueberauth_facebook/blob/master/lib/ueberauth/strategy/facebook.ex

LINE 109 in https://github.com/fajarmf/ueberauth_linkedin/blob/master/lib/ueberauth/strategy/linkedin.ex

LINE 76 https://github.com/ueberauth/ueberauth_twitter/blob/master/lib/ueberauth/strategy/twitter.ex
  • Loading branch information
willykaram authored and doomspork committed Sep 1, 2017
1 parent d4800b0 commit 28e18a7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/ueberauth/strategy/github.ex
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ defmodule Ueberauth.Strategy.Github do
nickname: user["login"],
email: user["email"] || Enum.find(user["emails"] || [], &(&1["primary"]))["email"],
location: user["location"],
image: user["avatar_url"],
urls: %{
followers_url: user["followers_url"],
avatar_url: user["avatar_url"],
Expand Down

0 comments on commit 28e18a7

Please sign in to comment.