From 4878d6662035306a9c8eb8c0db02236b0a13df77 Mon Sep 17 00:00:00 2001 From: yystopf Date: Tue, 6 Sep 2022 09:04:46 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/forms/contents/create_form.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/forms/contents/create_form.rb b/app/forms/contents/create_form.rb index 71709026d..73341661c 100644 --- a/app/forms/contents/create_form.rb +++ b/app/forms/contents/create_form.rb @@ -3,7 +3,7 @@ class Contents::CreateForm < BaseForm validates :filepath, presence: true - validates :new_branch, length: { maximum: 50} + validates :new_branch, length: { maximum: 50, too_long: "分支名称过长,仅支持%{count}的长度"} validate :check_branch