class StoreSchema::Converter::String

Public Instance Methods

from_db() click to toggle source

Simply returns {#value} since it's already a String-type.

@return [String]

# File lib/store_schema/converter/string.rb, line 23
def from_db
  value
end
to_db() click to toggle source

Simply returns {#value} if it's a String.

@return [String, false] false if {#value} is an invalid date-type.

# File lib/store_schema/converter/string.rb, line 11
def to_db
  if value.is_a?(::String)
    value
  else
    false
  end
end