Read more

How to reload a belongs_to association

Dominik Schöler
December 03, 2018Software engineer at makandra GmbH

To reload a single-item association in Rails 5+, call #reload_<association>:

post.reload_author
Illustration web development

Do you need DevOps-experts?

Your development team has a full backlog? No time for infrastructure architecture? Our DevOps team is ready to support you!

  • We build reliable cloud solutions with Infrastructure as code
  • We are experts in security, Linux and databases
  • We support your dev team to perform
Read more Show archive.org snapshot

In older Railses you can say

post.author(true)
Posted by Dominik Schöler to makandra dev (2018-12-03 16:13)