title: Fetch value from session Rails
body: <p>I'm using a link and send some of the parameter with them, </p>
  
  <pre><code>%a{:href =&gt; "/auth/#{key}?profile_id=#{@user.id}&amp;profile_type=user}
  </code></pre>
  
  <p>These parameter goes in session and after that save in db.
  Before saving in the db, I want to fetch value of these parameter ,for this I use in my application controller:</p>
  
  <pre><code>before_filter :social_media_type
  
   def social_media_type
     Rails.logger.debug"***********Session Set*****#{params[:profile_id]}*********#{params[:profile_type]}***"
     if params[:profile_type].present? and params[:profile_id].present?      
      session[:social_profile_type] = params[:profile_type]
      session[:social_profile_id] = params[:profile_id]
     end
  end
  </code></pre>
  
  <p>But here is a problem, It does not fetch any value when I check it in logger.
  Is it not correct or have any error? please give your suggestion. </p>