From ffafa01d85bc4b358f01bf1cc5f5c5986e8fe287 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steve=20Fr=C3=A9cinaux?= Date: Tue, 4 Mar 2025 22:22:19 +0100 Subject: [PATCH] Make the bookmark title field length consistent with the model The model specifies a max length of 160 for the title column, but the form template specified a max length of 100 for the title field. Indeed, if you look in db/schema.rb you'll find: t.string "title", limit: 160, null: false --- app/views/bookmarks/_form.html.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/bookmarks/_form.html.haml b/app/views/bookmarks/_form.html.haml index 5c94b3a65..8cdaef4e8 100644 --- a/app/views/bookmarks/_form.html.haml +++ b/app/views/bookmarks/_form.html.haml @@ -2,7 +2,7 @@ %p = form.label :title, "Sujet du lien" - = form.text_field :title, autocomplete: 'off', required: 'required', spellcheck: 'true', maxlength: 100 + = form.text_field :title, autocomplete: 'off', required: 'required', spellcheck: 'true', maxlength: 160 %p = form.label :link, "Lien à partager" = form.text_field :link, autocomplete: 'off', required: 'required', spellcheck: 'false', maxlength: 1024