Fixed issue 23946. The backend restriction will not be checked if there is no way to retrieve the role.
authorAntonio Moreno <antonio.moreno@openbravo.com>
Thu, 30 May 2013 13:35:55 +0200
changeset 20499 22cf29c433bb
parent 20498 e614965c64cc
child 20500 7331622675df
Fixed issue 23946. The backend restriction will not be checked if there is no way to retrieve the role.
src/index.jsp
--- a/src/index.jsp	Thu May 30 16:13:40 2013 +0530
+++ b/src/index.jsp	Thu May 30 13:35:55 2013 +0200
@@ -177,7 +177,7 @@
   }else{
     role = OBDal.getInstance().get(Role.class, vars1.getRole());
   }
-if(role.isRestrictbackend()){
+if(role !=null && role.isRestrictbackend()){
 %>
   document.body.removeChild(document.getElementById('OBLoadingDiv'));
   isc.Dialog.create({message: OB.I18N.getLabel('OBUIAPP_RestrictedUser'), title: OB.I18N.getLabel('OBUIAPP_RestrictedUserTitle'), showCloseButton: false}).show();