Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

wrong class when using scope together with sti

#4651

Using rails beta3 and ruby 1.9.2-head.

class User < ActiveRecord::Base
scope :active, where(:active => true) end

class NormalUser < User
end

User.active.first.class
=> User

NormalUser.first.class
=> NormalUser

NormalUser.active.first.class
=> User (should be NormalUser!!!)

Reported by gucki · May 19th, 2010 @ 10:05 AM

State: resolved
Milestone: none
Assigned to: nobody
Importance: High

Activity

  1. gucki
    gucki

    Just upgraded to the latest rails version from git and it's working fine now. So I guess this bug has already been fixed and this ticket can be closed. :)

    May 19th, 2010 @ 10:34 AM

  2. Rizwan Reza
    Rizwan Reza
    • No changes were found…

    May 21st, 2010 @ 12:45 AM

  3. Rohit Arondekar
    Rohit Arondekar
    • State changed from new to resolved

    June 15th, 2010 @ 09:57 AM