<commit_before># encoding: utf-8
require 'cgi'

module Github
  class Client::Users::Emails < API

    # List email addresses for the authenticated user
    #
    # = Examples
    #  github = Github.new :oauth_token => '...'
    #  github.users.emails.list
    #  github.users.emails.list { |email| ... }
    #
    def list(*args)
      arguments(args)
      response = get_request("/user/emails", arguments.params)
      return response unless block_given?
      response.each { |el| yield el }
    end
    alias :all :list

    # Add email address(es) for the authenticated user
    #
    # = Inputs
    # You can include a single email address or an array of addresses
    #
    # = Examples
    #  github = Github.new :oauth_token => '...'
    #  github.users.emails.add "<EMAIL>", "<EMAIL>"
    #
    def add(*args)
      arguments(args)
      params = arguments.params
      params['data'] = arguments.remaining unless arguments.remaining.empty?

      post_request("/user/emails", params)
    end
    alias :<< :add

    # Delete email address(es) for the authenticated user
    #
    # = Inputs
    # You can include a single email address or an array of addresses
    #
    # = Examples
    #  github = Github.new :oauth_token => '...'
    #  github.users.emails.delete "<EMAIL>", "<EMAIL>"
    #
    def delete(*args)
      arguments(args)
      params = arguments.params
      params['data'] = arguments.remaining unless arguments.remaining.empty?

      delete_request("/user/emails", params)
    end

  end # Users::Emails
end # Github<commit_msg>Change docs for user emails api.<commit_after># encoding: utf-8
require 'cgi'

module Github
  class Client::Users::Emails < API

    # List email addresses for the authenticated user
    #
    # @example
    #  github = Github.new oauth_token: '...'
    #  github.users.emails.list
    #  github.users.emails.list { |email| ... }
    #
    # @return [Hash]
    #
    # @api public
    def list(*args)
      arguments(args)
      response = get_request("/user/emails", arguments.params)
      return response unless block_given?
      response.each { |el| yield el }
    end
    alias :all :list

    # Add email address(es) for the authenticated user
    #
    # @param [Array[String]] emails
    #   You can include a single email address or an array of addresses
    #
    # @example
    #  github = Github.new oauth_token: '...'
    #  github.users.emails.add "<EMAIL>", "<EMAIL>"
    #
    # @api public
    def add(*args)
      arguments(args)
      params = arguments.params
      params['data'] = arguments.remaining unless arguments.remaining.empty?

      post_request("/user/emails", params)
    end
    alias :<< :add

    # Delete email address(es) for the authenticated user
    #
    # @param [Array[String]] emails
    #   You can include a single email address or an array of addresses
    #
    # @example
    #  github = Github.new oauth_token: '...'
    #  github.users.emails.delete "<EMAIL>", "<EMAIL>"
    #
    # @api public
    def delete(*args)
      arguments(args)
      params = arguments.params
      params['data'] = arguments.remaining unless arguments.remaining.empty?

      delete_request("/user/emails", params)
    end
  end # Users::Emails
end # Github
{'fraction_non_alphanumeric': 0.12123076923076923, 'fraction_numerical': 0.0006153846153846154, 'mean_word_length': 2.507011866235167, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 14, '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': '4115099', 'n_tokens_mistral': 1020, 'n_tokens_neox': 983, 'n_words': 268}