Newer
Older
2018-fumichan-thesis / sinatra-practice / form-sample / vendor / bundle / ruby / 2.5.0 / gems / activesupport-5.2.1 / lib / active_support / core_ext / string / exclude.rb
# frozen_string_literal: true

class String
  # The inverse of <tt>String#include?</tt>. Returns true if the string
  # does not include the other string.
  #
  #   "hello".exclude? "lo" # => false
  #   "hello".exclude? "ol" # => true
  #   "hello".exclude? ?h   # => false
  def exclude?(string)
    !include?(string)
  end
end