<commit_before>module GiveyRails
  class Charity
    include GiveyRails::GiveyModel

    attr_accessor :id,
      :name,
      :givey_tag,
      :info_description,
      :description,
      :avatar_url,
      :avatar_thumb_url,
      :charity_donations_total,
      :time_donation_accepted,
      :stuff_donation_accepted,
      :has_channels,
      :channels,
      :donors,
      :donor_count,
      :supporters,
      :supporter_count,
      :has_admin_user,
      :node_type

    def name_and_tag
      "#{givey_tag} - #{name}"
    end

    def user_donations_total
      Money.new(@user_donations_total).cents / 100
    end

    def charity_donations_total_display 
      Money.new(@charity_donations_total).cents / 100
    end

    # default currency
    def currency
      @currency.blank? ? 'GBP' : @currency
    end

    def display_currency
      Money.new(0, currency).currency
    end

  end
end
<commit_msg>GIVEY-335 #comment add categories to Charity model<commit_after>module GiveyRails
  class Charity
    include GiveyRails::GiveyModel

    CATEGORIES  = [
      #"Culture, Sport, and Recreation",
      "Education and Science",
      "Health and Medicine",
      "Social Services and Relief",
      "Environment and Protection of Animals",
      "Housing and Community Affairs",
      "Civil Rights and Citizenship",
      "Philanthropic Intermediation",
      "International",
      "Business and Professional",
      "Religious"
    ]


    attr_accessor :id,
      :name,
      :givey_tag,
      :info_description,
      :description,
      :avatar_url,
      :avatar_thumb_url,
      :charity_donations_total,
      :time_donation_accepted,
      :stuff_donation_accepted,
      :has_channels,
      :channels,
      :donors,
      :donor_count,
      :supporters,
      :supporter_count,
      :has_admin_user,
      :node_type

    def name_and_tag
      "#{givey_tag} - #{name}"
    end

    def user_donations_total
      Money.new(@user_donations_total).cents / 100
    end

    def charity_donations_total_display 
      Money.new(@charity_donations_total).cents / 100
    end

    # default currency
    def currency
      @currency.blank? ? 'GBP' : @currency
    end

    def display_currency
      Money.new(0, currency).currency
    end

  end
end

{'fraction_non_alphanumeric': 0.08333333333333333, 'fraction_numerical': 0.007456140350877193, 'mean_word_length': 2.471841704718417, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '4019488', 'n_tokens_mistral': 779, 'n_tokens_neox': 726, 'n_words': 151}