Details
-
Bug
-
Status: Closed
-
Normal
-
Resolution: Fixed
-
None
-
None
-
None
-
Turing Sprint 192, Turing Sprint 191, Turing Sprint 193
Description
Currently, the code is as follows:
private boolean isModified(final DocumentVariant unpublished, final DocumentVariant published) { try { return unpublished.getLastModified().after(published.getLastModified()); } catch (RepositoryException e) { log.error("Cannot determine if document {} is modified, returning false", unpublished.getIdentity(), e); return false; } }
This means that if you restore a document from version history with a last modified timestamp that is before the published timestamp, the isModified returns false and IIRC, the document cannot be published. AFAICS, isModified should check for last modified inequality, not before/after logic