ilgrosso commented on code in PR #1278:
URL: https://github.com/apache/syncope/pull/1278#discussion_r2653121125


##########
client/idrepo/console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java:
##########
@@ -187,7 +187,7 @@ protected void populateItem(final ListItem<Class<? extends 
BasePage>> item) {
                 IdMPage ann = 
item.getModelObject().getAnnotation(IdMPage.class);
 
                 BookmarkablePageLink<Page> link = new 
BookmarkablePageLink<>("idmPage", item.getModelObject());
-                link.add(new Label("idmPageLabel", ann.label()));
+                link.add(new Label("idmPageLabel", getString(ann.label())));

Review Comment:
   Use the `getString()` variant with default, e.g.
   
   ```java
   getString(ann.label(), null, ann.label())
   ```
   
   so it will work even when the actual translation is not available



##########
client/idrepo/console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java:
##########
@@ -226,7 +226,7 @@ protected void populateItem(final ListItem<Class<? extends 
BasePage>> item) {
                 AMPage ann = item.getModelObject().getAnnotation(AMPage.class);
 
                 BookmarkablePageLink<Page> link = new 
BookmarkablePageLink<>("amPage", item.getModelObject());
-                link.add(new Label("amPageLabel", ann.label()));
+                link.add(new Label("amPageLabel", getString(ann.label())));

Review Comment:
   same here



##########
client/idrepo/console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.properties:
##########
@@ -33,3 +33,7 @@ endDelegation=End Delegation
 sessionExpiration.header=Session Expiration
 sessionExpiration.body=Your session is about to expire. Please select the 
appropriate option to keep working.
 sessionExpiration.extend=Extend
+

Review Comment:
   These labels shall be provided in the same module where the corresponding 
page is located, e.g. ``client/idm/console/src/main/resources/...` for 
`Topology`
   
   The other two labels are useless and should be removed.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to