title: Ruby. Variable permission
body: <p>I have a problem to access to variable in other method in this class. Here is my example:</p>
  
  <pre><code>class CustomersController &lt; ApplicationController
   def login
     if params[:login].present? &amp;&amp; params[:password].present?
       **@cust_model** = Customers.new
       redirect_to(:action =&gt; 'client_dashboard')
     end
   end
   def client_dashboard
    @cust_dashboard = **@cust_model**.dashboard(1)
   end 
  end
  </code></pre>
  
  <p>My error is: undefined method dashboard</p>