Skip to content

Cannot use :as with .new with child objects - ArgumentError: wrong number of arguments (2 for 0..1) #21

Closed
@espen

Description

@espen
  1. List has_many items.
  2. Using list.items.create({}, :as => :admin) works.
  3. Using list.items.new({}, :as => :admin) works in Rails3 gives error with this gem: 'ArgumentError: wrong number of arguments (2 for 0..1)'

See failing test at https://github.com/espen/protected_attributes_new_bug

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions