Skip to content

method_missing on params object ignores arguments #112

@timbertson

Description

@timbertson

When a task receives a params object whose inspect prints {:subdomain=>"support”}, calling params.fetch(:support) surprisingly returns nil. Clearly this is not a hash.

It looks like this is implemented via a method_missing which performs lookup. This implementation should throw if any arguments are passed, because if you're providing arguments you clearly didn't expect this to be a simple getter method.

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