title: Get redirect of a URL in Ruby
body: <p>According to Facebook graph API we can request a user profile picture with this (example):</p>
  
  <pre><code>https://graph.facebook.com/1489686594/picture
  </code></pre>
  
  <p>But the real image URL of the previous link is:</p>
  
  <p><code>http://profile.ak.fbcdn.net/hprofile-ak-snc4/hs356.snc4/41721_1489686594_527_q.jpg</code></p>
  
  <p>If you type the first link on your browser, it will redirect you to the second link.</p>
  
  <p>Is there any way to get the full URL (second link) with Ruby/Rails, by only knowing the first URL?</p>
  
  <p>(This is a repeat of <a href="https://stackoverflow.com/questions/3535222/get-facebook-real-profile-image-url">this question</a>, but for Ruby)</p>