From 2e1abcf27f1b025e1cf9c04a44a7b857301f039a Mon Sep 17 00:00:00 2001 From: Andy Damevin Date: Thu, 18 Jan 2024 09:36:19 +0100 Subject: [PATCH] Apply suggestions from code review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Stéphane Épardaud --- integration-tests/src/main/java/rest/HtmxApp.java | 4 ++-- runtime/src/main/resources/templates/tags/gravatar.html | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/integration-tests/src/main/java/rest/HtmxApp.java b/integration-tests/src/main/java/rest/HtmxApp.java index 739a0c6..dfffb42 100644 --- a/integration-tests/src/main/java/rest/HtmxApp.java +++ b/integration-tests/src/main/java/rest/HtmxApp.java @@ -44,14 +44,14 @@ public TemplateInstance index() { return Templates.index(contactService.contacts().values()); } - public TemplateInstance view(@RestPath("id") int id) { + public TemplateInstance view(@RestPath int id) { if (!contactService.contacts().containsKey(id)) { throw new IllegalArgumentException("Invalid id: " + id); } return Templates.view(contactService.contacts().get(id)); } - public TemplateInstance edit(@RestPath("id") int id) { + public TemplateInstance edit(@RestPath int id) { if (!contactService.contacts().containsKey(id)) { throw new IllegalArgumentException("Invalid id: " + id); } diff --git a/runtime/src/main/resources/templates/tags/gravatar.html b/runtime/src/main/resources/templates/tags/gravatar.html index 4ff0296..411cc2d 100644 --- a/runtime/src/main/resources/templates/tags/gravatar.html +++ b/runtime/src/main/resources/templates/tags/gravatar.html @@ -1 +1 @@ -