Sha256: 006ed8b14d9076fd11deff8b802a6d3a82e46d5261f5d4a0a7beda8147edc851
Contents?: true
Size: 418 Bytes
Versions: 7
Compression:
Stored size: 418 Bytes
Contents
module CouchPillow module TypeDirective # Sets the type of this Document. # def type value @type = value.to_s end def _doc_type @type ||= "couchpillow" end # Helper method to sanitize an id string # def _sanitize_id id key = "#{_doc_type}::" id = id.to_s id.start_with?(key) and id = id[key.length..-1] or id end end end
Version data entries
7 entries across 7 versions & 1 rubygems