Details

    • Bug
    • Status: Verified
    • Resolution: Unresolved
    • 7.1.0 CE GA1
    • None
    • Recycle Bin
    • 1

    Description

      Take a look at the com.liferay.trash.taglib.servlet.taglib.UndoTag class and its following method:

       

      private Map<String, Object> _getData() {
         ThemeDisplay themeDisplay = (ThemeDisplay)request.getAttribute(
            WebKeys.THEME_DISPLAY);
      
         PortletRequest portletRequest = (PortletRequest)request.getAttribute(
            JavaConstants.JAVAX_PORTLET_REQUEST);
      
         PortletDisplay portletDisplay = themeDisplay.getPortletDisplay();
      
         String key =
            portletDisplay.getId() +
               SessionMessages.KEY_SUFFIX_DELETE_SUCCESS_DATA;
      
         if (!SessionMessages.contains(portletRequest, key)) {
            return null;
         }
      
         return (HashMap<String, Object>)SessionMessages.get(
            portletRequest, key);
      }
      

      You get CCE in the return statement if something different from HashMap accessible by the key.

      I've faced with it when passed Collections.singletonMap to BaseMVCActionCommand.addDeleteSuccessData.

      Attachments

        Activity

          People

            support-lep@liferay.com SE Support
            alexey_afanasyev Alexey Afanasyev (Inactive)
            Kiyoshi Lee Kiyoshi Lee
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              4 years, 30 weeks ago

              Packages

                Version Package