<commit_before>class Pupil
  def friends_ids(name=@screen_name)
    response = self.get("/friends/ids/#{name}.json")
    return false unless response
    ids = []
    response.each do |element|
      ids << element
    end
    return ids
  end

  def followers_ids(name=@screen_name)
    response = self.get("/1/followers/ids/#{name}.json")
    return false unless response
    ids = []
    response.each do |element|
      ids << element
    end
    return ids
  end
  
  # Check friendships
  # @param [String] src source screen_name
  # @param [String] dst destination screen_name
  # @return [Boolean] return true if paired users have friendship, or ruturn false
  def friendship?(src, dst)
    param = {"source_#{guess_parameter(src)}" => src, "target_#{guess_parameter(dst)}" => dst}
    response = self.get("/friendships/show.json", param)
    return nil unless response
    if response["relationship"]["source"]["following"] == true && response["relationship"]["target"]["following"] == true then
      return true
    else
      return false
    end
  end
  
  alias_method "relationship?", "friendship?"
  alias_method "friendships_exists?", "friendship?"

  # Follow user for screen_name
  # @param [String] name screen_name
  # @return [Hash] response
  def follow(param)
    response = self.post("/friendships/create.json", {guess_parameter(param) => param})
    return false unless response
    User.new(response, @access_token)
  end

  # Unfollow user for screen_name
  # @param [String] name screen_name
  # @return [Hash] response
  def unfollow(param)
    response = self.post("/friendships/destroy.json", {guess_parameter(param) => param})
    return false unless response
    User.new response
  end
end<commit_msg>fixed bug that error cause on friends_ids<commit_after>class Pupil
  def friends_ids(name=@screen_name)
    response = self.get("/1/friends/ids/#{name}.json")
    return false unless response
    ids = []
    response.each do |element|
      ids << element
    end
    return ids
  end

  def followers_ids(name=@screen_name)
    response = self.get("/1/followers/ids/#{name}.json")
    return false unless response
    ids = []
    response.each do |element|
      ids << element
    end
    return ids
  end
  
  # Check friendships
  # @param [String] src source screen_name
  # @param [String] dst destination screen_name
  # @return [Boolean] return true if paired users have friendship, or ruturn false
  def friendship?(src, dst)
    param = {"source_#{guess_parameter(src)}" => src, "target_#{guess_parameter(dst)}" => dst}
    response = self.get("/friendships/show.json", param)
    return nil unless response
    if response["relationship"]["source"]["following"] == true && response["relationship"]["target"]["following"] == true then
      return true
    else
      return false
    end
  end
  
  alias_method "relationship?", "friendship?"
  alias_method "friendships_exists?", "friendship?"

  # Follow user for screen_name
  # @param [String] name screen_name
  # @return [Hash] response
  def follow(param)
    response = self.post("/friendships/create.json", {guess_parameter(param) => param})
    return false unless response
    User.new(response, @access_token)
  end

  # Unfollow user for screen_name
  # @param [String] name screen_name
  # @return [Hash] response
  def unfollow(param)
    response = self.post("/friendships/destroy.json", {guess_parameter(param) => param})
    return false unless response
    User.new response
  end
end
{'fraction_non_alphanumeric': 0.11907481439177613, 'fraction_numerical': 0.0008566533409480297, 'mean_word_length': 3.645888594164456, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1647829', 'n_tokens_mistral': 1047, 'n_tokens_neox': 1040, 'n_words': 295}