#14 √ resolved
Aneem

NoMethodError in UsersController#update_password

Reported by Aneem | November 6th, 2008 @ 04:36 PM | in BaseApp 1.0

url(http://localhost:3000/users/1/ed...

undefined method encrypt' for #<Class:0x4232658>

RAILS_ROOT: C:/ruby/work/baseapp Application Trace | Framework Trace | Full Trace

c:/ruby/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/base.rb:1672:in method_missing_without_paginate' vendor/plugins/will_paginate/lib/will_paginate/finder.rb:82:inmethod_missing' app/controllers/users_controller.rb:138:in update_password'

Comments and changes to this ticket

  • baseapp (at ariejan)

    baseapp (at ariejan) November 10th, 2008 @ 10:30 AM

    • → State changed from “new” to “hold”
    • → Milestone changed from “” to “BaseApp 1.0”

    Did you update the BaseApp code, but not restart your server? I can't reproduce the error you get locally.

  • Abraão Coelho

    Abraão Coelho November 10th, 2008 @ 01:14 PM

    • → Tag changed from “” to “baseapp encrypt password”

    Well... I got that error either...

    But, at the bottom of User model there is a method encrypt, which is commented... I uncommented and I didn't get this error anymore...

    But, when I try to update my password I keep getting the message "Your current password is wrong" - or something like that.

  • baseapp (at ariejan)

    baseapp (at ariejan) November 10th, 2008 @ 01:34 PM

    • → State changed from “hold” to “open”

    We've moved to a new version of restful authentication.

    Old password are no longer valid.

    The 'encrypt' method is not in the User model anymore, but in a mixin store in the restful_authentication plugin.

    Best work around is to disable/comment the encrypt method in the User model and open a console session to update your password there.

    Could you close this ticket if the aboves solves your issue?

  • Aneem

    Aneem November 10th, 2008 @ 01:51 PM

    Since you've moved to a new version of restful authentication, can we download the updated BaseApp code?

  • Ariejan de Vroom

    Ariejan de Vroom November 10th, 2008 @ 02:00 PM

    Yes you can. Just do a git pull

  • Aneem

    Aneem November 10th, 2008 @ 03:53 PM

    The latest code commented out encrypt method in user model. But in users_controller(ln 138) 'encrypt' method is still used.

    So the new error is:

    undefined method encrypt' for #<Class:0x424e498>

    RAILS_ROOT: C:/ruby/work/baseapp2 Application Trace | Framework Trace | Full Trace

    c:/ruby/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/base.rb:1672:in method_missing_without_paginate' vendor/plugins/will_paginate/lib/will_paginate/finder.rb:82:inmethod_missing' app/controllers/users_controller.rb:138:in update_password'

  • Pacifists

    Pacifists November 15th, 2008 @ 03:07 PM

    It looks like I've fixed this issue and sent a pull request to Ariejan. If anyone else needs the fix look here http://github.com/pacifists/base...

  • Ariejan de Vroom

    Ariejan de Vroom December 22nd, 2008 @ 03:01 PM

    • → State changed from “open” to “resolved”

    Fix merged. Thanks!

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

BaseApp is the quick-start for your Rails App

Shared Ticket Bins

You can update this ticket by sending an email to from your email client. (help)