aboutsummaryrefslogtreecommitdiff
path: root/app/models/user.rb
blob: 7288412da41bce92801ae2b0832bfb72e2ac50a9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# SPDX-FileCopyrightText: 2020 IN COMMON Collective <collective@incommon.cc>
#
# SPDX-License-Identifier: AGPL-3.0-or-later

class User < ApplicationRecord
  has_many :agencies
  has_many :agents, through: :agencies, source: :agent

  include UsersHelper

  def avatar_url
    attributes[:avatar_url] || default_user_avatar_url
  end
end