Rails: before_destroyによる関連チェックに注意 22 Mar 2016 ruby / rails before_destroyの実行順序を考えないと、バリデーションが予期しない動作になる事がある。