Skip to content

Ignoring Redis fields that are missing in the model? #234

@rgaufman

Description

@rgaufman

When I change my model, any fields that are still present in Redis cause a NoMethodError, e.g.

> Device.all.entries[0]
Traceback (most recent call last):
        2: from (irb):5
        1: from (irb):5:in `entries'
NoMethodError (undefined method `created_at=' for #<Device:0x0000000004c48278 @attributes={}, @_memo={}>)

Is there any way to get Ohm to ignore any fields from Redis that are not in the model? - or is there some other recommended strategy to handle this?

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions