summaryrefslogtreecommitdiff
path: root/app/models/application_setting
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/application_setting')
-rw-r--r--app/models/application_setting/term.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/models/application_setting/term.rb b/app/models/application_setting/term.rb
index 723540c9b91..bab036f5697 100644
--- a/app/models/application_setting/term.rb
+++ b/app/models/application_setting/term.rb
@@ -14,6 +14,8 @@ class ApplicationSetting
end
def accepted_by_user?(user)
+ return true if user.project_bot?
+
user.accepted_term_id == id ||
term_agreements.accepted.where(user: user).exists?
end