Rails: jeśli zmieniła się relacja has_many

Mam te dwie klasy.

class Article < ActiveRecord::Base
  attr_accessible :body, :issue, :name, :page, :image, :video, :brand_ids
  has_many :publications
  has_many :docs, :through => :publications
end

class Doc < ActiveRecord::Base
  attr_accessible :issue_id, :cover_id, :message, :article_ids, :user_id, :created_at, :updated_at, :issue_code, :title, :template_id
  has_many :publications, dependent: :destroy
  has_many :articles, :through => :publications, :order => 'publications.position'
  has_many :edits, dependent: :destroy
  accepts_nested_attributes_for :articles, allow_destroy: false
end

Jak napisałbym instrukcję warunkową, aby sprawdzić, czy@doc.articles zmienił się po aktualizacji@doc?

if @doc.articles.changed?
  ...
end

Powyższe daje mi błąd. Nie mogę znaleźć poprawnej składni.

questionAnswers(3)

yourAnswerToTheQuestion