rb/lib/twitter-text/extractor.rb
# Helper function to count the character length by first converting to an
# array.  This is needed because with unicode strings, the return value
# of length may be incorrect
Helper function to count the character length by first converting to an
array.  This is needed because with unicode strings, the return value
of length may be incorrect
Helper function to count the character length by first converting to an array . This is needed because with unicode strings the return value of length may be incorrect
def codepoint_length
    if respond_to? :codepoints
      length
    else
      chars.kind_of?(Enumerable) ? chars.to_a.size : chars.size
    end
  end
def codepoint_length if respond_to? :codepoints length else chars . kind_of? ( Enumerable ) ? chars . to_a . size : chars . size end end
Helper function to count the character length by first converting to an
array.
Helper function to count the character length by first converting to an array .