@@ -87,6 +87,7 @@ public void doPost(HttpServletRequest request, HttpServletResponse response)
8787 enc .getAnnotations ().contains (myShepherd .getAnnotation (annotID ))
8888 ) {
8989 Annotation ann = myShepherd .getAnnotation (annotID );
90+ User user = myShepherd .getUser (request );
9091 // overall: don't delete trivial annotations. in that case, delete image command from menu
9192 // if not trivial but has no sibs, revert to trivial
9293 if (!ann .isTrivial () &&
@@ -100,6 +101,9 @@ public void doPost(HttpServletRequest request, HttpServletResponse response)
100101 }
101102 Annotation newAnnot = ann .revertToTrivial (myShepherd );
102103
104+ enc .addComments ("<p data-annot-id=\" " + ann .getId () +
105+ "\" >Annotation deleted by " + user .getDisplayName () + " on " +
106+ Util .prettyTimeStamp () + "</p>" );
103107 myShepherd .getPM ().deletePersistent (ann );
104108 myShepherd .updateDBTransaction ();
105109 res .put ("revertToTrivial" , true );
@@ -113,6 +117,9 @@ else if (!ann.isTrivial()) {
113117 myShepherd .updateDBTransaction ();
114118 }
115119 }
120+ enc .addComments ("<p data-annot-id=\" " + ann .getId () +
121+ "\" >Annotation deleted by " + user .getDisplayName () + " on " +
122+ Util .prettyTimeStamp () + "</p>" );
116123 enc .removeAnnotation (ann );
117124 myShepherd .getPM ().deletePersistent (ann );
118125 myShepherd .commitDBTransaction ();
0 commit comments