Skip to content

To access new custom methods in Rails, we have to reload the spring #566

@imam

Description

@imam

First, I add an admin? method to User

image

image

It works! Of course rails c will run spring in the background.

Now I'll change admin? to isAdmin?

image

I'll restart the server and try to access the isAdmin? method

image

Not working!

image

And admin? method still exist there.

To resolve this issue I have to reload the spring after exiting the console:

image

Then it's working!

Of course, I expect that I don't have to restart the spring to reload the model methods, I expect to just have to exit the console to have it reloaded.

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