Sha256: 5c6a629e72f31759b8a463c2cde4dea01f7c7ff1fa7507d2a4abcaf6ed4f23fa

Contents?: true

Size: 229 Bytes

Versions: 5

Compression:

Stored size: 229 Bytes

Contents

module Datewari
  class Util
    class << self
      def parse_date(date)
        if date.is_a?(String)
          Date.parse(date)
        else
          date
        end
      rescue => e
        nil
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
datewari-1.1.0 lib/datewari/util.rb
datewari-1.0.3 lib/datewari/util.rb
datewari-1.0.2 lib/datewari/util.rb
datewari-1.0.1 lib/datewari/util.rb
datewari-1.0.0 lib/datewari/util.rb