Sha256: 3ad1b3aa9c48cd3f6656eda125cac9cb2c0ec4c46ee190a8f7c3f6834ff642b7
Contents?: true
Size: 479 Bytes
Versions: 8
Compression:
Stored size: 479 Bytes
Contents
module Storytime class Autosave < ActiveRecord::Base include Storytime::ScopedToSite belongs_to :user, class_name: Storytime.user_class belongs_to :autosavable, polymorphic: true attr_accessor :draft_content before_save :update_autosave_content def update_autosave_content self.content = if Storytime.post_sanitizer.blank? @draft_content else Storytime.post_sanitizer.call(@draft_content) end end end end
Version data entries
8 entries across 8 versions & 1 rubygems