contributors: Fix broken test

GitHub recently made a change on their end to the URLs with which
profile images are stored. As a result, this has caused the profile
images on the About Us page to break, and tests to fail.

This updates the URL to what GitHub has switched to, in order to resolve
the issue.
This commit is contained in:
Will Binns 2017-03-07 09:11:24 -06:00
parent 1020e06d7d
commit 77fd49b107
No known key found for this signature in database
GPG key ID: 302EBEAEEB74A404

View file

@ -59,7 +59,7 @@ module Jekyll
x['name'] = name x['name'] = name
x['contributions'] = c['contributions'] x['contributions'] = c['contributions']
# Set avatar_url when available # Set avatar_url when available
if c.has_key?('avatar_url') and c['avatar_url'].is_a?(String) and /^https:\/\/avatars\.githubusercontent\.com\/u\/[0-9]{1,10}\?v=[0-9]{1,2}$/.match(c['avatar_url']) if c.has_key?('avatar_url') and c['avatar_url'].is_a?(String) and /^https:\/\/avatars1\.githubusercontent\.com\/u\/[0-9]{1,10}\?v=[0-9]{1,2}$/.match(c['avatar_url'])
x['avatar_url'] = c['avatar_url'] + '&size=16' x['avatar_url'] = c['avatar_url'] + '&size=16'
end end
# Set login when available # Set login when available