On Aug 2, 10:01 am, "Rzepak G." <[email protected]>
wrote:
> Hi,
> I'm beginner in rails, and I wanted to add to my simple application
> Authlogic. So I've watchedhttp://railscasts.com/episodes/160-authlogic
> and step-by-step done everything. And almost everything works fine,
> except login in. After registration new user is automatically logged in,
> he can edit his profile, but after clicking logout and trying to login
> again I get error
>
> NoMethodError in User sessionsController#create
>
> undefined method `mb_chars' for "rzepak":String
>
> My user_session_controller.rb:
>
> class UserSessionsController < ApplicationController
>   def new
>     @user_session = UserSession.new
>   end
>
> def create
>   @user_session = UserSession.new(params[:user_session])
>   if @user_session.save
>     flash[:notice] = "Successfully logged in."
>     redirect_to root_url
>   else
>     render :action => 'new'
>   end
> end
>
> def destroy
>   current_user_session.destroy
>   flash[:notice] = "Successfully logged out."
>   redirect_to root_url
> end
>
> end
>
> I was trying to google this error, but with no success, so I hope I will
> find some help here
>
> gem -v 1.3.5
> ruby -v ruby 1.8.7 (2008-08-11 patchlevel 72) [i486-linux]

You didn't post your view, but, maybe a typo via "User
sessionsController"?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to