9 lines
165 B
Ruby
9 lines
165 B
Ruby
|
class Feed < ActiveRecord::Base
|
||
|
has_many :items
|
||
|
|
||
|
validates_uniqueness_of :url
|
||
|
validates_presence_of :title
|
||
|
|
||
|
scope :recent, order(:published, :asc).limit(10)
|
||
|
end
|