From 6805cc287ef4700d3223fe9172632fd8f58c5c2f Mon Sep 17 00:00:00 2001 From: Gerhard Schlager Date: Tue, 13 Jul 2021 17:08:51 +0200 Subject: [PATCH] FIX: Allow uppercase letters in automatic group names `User.username_exists?` always converts to lowercase during lookup, so this change should be safe. --- app/models/group.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/group.rb b/app/models/group.rb index 8a6d7183a3a..4832b9a7743 100644 --- a/app/models/group.rb +++ b/app/models/group.rb @@ -437,7 +437,7 @@ class Group < ActiveRecord::Base end # don't allow shoddy localization to break this - localized_name = User.normalize_username(I18n.t("groups.default_names.#{name}", locale: SiteSetting.default_locale)) + localized_name = I18n.t("groups.default_names.#{name}", locale: SiteSetting.default_locale) validator = UsernameValidator.new(localized_name) if validator.valid_format? && !User.username_exists?(localized_name)