Sha256: 16f420e344f260067eb0ff57f5edab874292882bd3378634c59266666fcc04e8
Contents?: true
Size: 415 Bytes
Versions: 3
Compression:
Stored size: 415 Bytes
Contents
module Twitter module Rails module Helpers def twitter_profile_pic(user, options={}) id = user.respond_to?(:twitter_id) ? user.twitter_id : user begin image_url = Twitter.user(id).profile_image_url rescue image_url = "http://static.twitter.com/images/default_profile_normal.png" end image_tag(image_url, options) end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
szimek-twitter_rails-0.0.3 | lib/twitter/rails/helpers.rb |
szimek-twitter_rails-0.0.4 | lib/twitter/rails/helpers.rb |
szimek-twitter_rails-0.0.5 | lib/twitter_rails/rails/helpers.rb |