foodcoopsat / foodsoft_hackathon

Other
1 stars 2 forks source link

Remove `Article` -> `ArticleVersion` delegates #91

Open lentschi opened 2 months ago

lentschi commented 2 months ago

As soon as all callers refer directly to article_version for their fields, remove those delegates: https://github.com/foodcoopsat/foodsoft_hackathon/blob/bb044e6d2b80c838b1c083114e17729f5537e4a2/app/models/article.rb#L74

For example instead of calling article.name we should be calling article.latest_article_version.name. Finding all those calls in an untyped language might be quite some effort though.