lib/wpb/pagepost.rb in wpb-0.0.6.pre vs lib/wpb/pagepost.rb in wpb-0.0.6

- old
+ new

@@ -9,36 +9,11 @@ validates_presence_of :post_author has_many :comments, :foreign_key => :comment_post_ID - ## - # Grab the title of the selected page/post - - def title - post_title - end - - ## - # Set the title of the selected page/post - - def title= new_title - self.post_title = new_title - end - - ## - # Grab the content of the selected page/post - - def content - post_content - end - - ## - # Set the content of the selected page/post - - def content= new_content - self.post_content = new_content - end + alias_attribute :title, :post_title + alias_attribute :content, :post_content private def set_default_values t = Time.now self.post_date = t \ No newline at end of file