From 7a193d664736866281420a12dcbbedc8d1fca013 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A2u=20Cao?= Date: Thu, 6 Apr 2023 16:25:01 +0200 Subject: [PATCH] Add comment --- app/models/user.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/models/user.rb b/app/models/user.rb index 5b40929..94c3b14 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -22,6 +22,7 @@ class User < ApplicationRecord validates_format_of :cn, without: /\A-/, if: Proc.new{ |u| u.cn.present? }, message: "is invalid. Usernames need to start with a letter." + # FIXME This needs a server restart to apply values validates_format_of :cn, without: /\A(#{Setting.reserved_usernames.join('|')})\z/i, message: "has already been taken"