Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-11645

FilesystemAttachmentRecycleBinStore.getAllDeletedAttachments does not allow null attachment argument

    XMLWordPrintable

Details

    • Unknown

    Description

      The javadoc for com.xpn.xwiki.store.AttachmentRecycleBinStore says:

           * @param attachment Optional attachment template. If <code>null</code>, return information about all deleted
           *            attachments from the database. Otherwise, filter by the document and filename provided in the passed
           *            attachment.
      

      however the org.xwiki.store.legacy.store.internal.FilesystemAttachmentRecycleBinStore who implements that interface does not support passing in "null" as attachment argument; instead it throws n NPE.

      This causes ADMINTOOL-12 (the second half) ... not sure if this should be fixed in the FilesystemAttachmentRecycleBinStore, or instead the javadoc should be updated (it seems loading 'DeletedAttachment' via HQL is the preferred solution to query for attachments anyway ?)

      Attachments

        Issue Links

          Activity

            People

              tmortagne Thomas Mortagne
              camil7 Clemens Robbenhaar
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: