From 1660515fc6d91b9933dd260ec22ba75bfb792e5e Mon Sep 17 00:00:00 2001 From: Roland Haeder Date: Wed, 13 Apr 2016 19:04:58 +0200 Subject: [PATCH] Better return same object as other controllers may want to modify (add/change/delete) it. --- .../beans/shop/PizzaShopWebApplicationBean.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/java/org/mxchange/pizzaapplication/beans/shop/PizzaShopWebApplicationBean.java b/src/java/org/mxchange/pizzaapplication/beans/shop/PizzaShopWebApplicationBean.java index 1fbe8458..a502e025 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/shop/PizzaShopWebApplicationBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/shop/PizzaShopWebApplicationBean.java @@ -87,10 +87,10 @@ public class PizzaShopWebApplicationBean implements PizzaShopWebApplicationContr } @Override + @SuppressWarnings ("ReturnOfCollectionOrArrayField") public List getAllCategories () throws FacesException { // Return it - // TODO Find something better here to prevent warning - return Collections.unmodifiableList(this.categories); + return this.categories; } @Override -- 2.39.5