Sha256: f74589d4f567a2033812c9985451d01fbe01dcc60781f1c0fd177f9adaa657f1
Contents?: true
Size: 134 Bytes
Versions: 3
Compression:
Stored size: 134 Bytes
Contents
class String def is_valid_json? JSON.parse(self) return true rescue JSON::ParserError => e return false end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
cotcube-helpers-0.1.3 | lib/cotcube-helpers/string_ext.rb |
cotcube-helpers-0.1.2 | lib/cotcube-helpers/string_ext.rb |
cotcube-helpers-0.1.1 | lib/cotcube-helpers/string_ext.rb |