branch: elpa/annotate
commit 7415bcca1b0d3e55020cc8fa7b85f3de41d378a1
Author: cage <cage@invalid>
Commit: cage <cage@invalid>

    - prevented printing of warning when saving a buffer that has no file under 
the hood and no annotation.
    
      `annotate-save-annotations' printed  a warning if the  buffer is not
      based on a file's contents. But  the warning was printed even if the
      buffer contained no annotations at all.
    
      this patch prints the warning about  missing file only if the buffer
      is annotated (i.e. contains at leas an annotation).
---
 annotate.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/annotate.el b/annotate.el
index 324afd4f12..15b60c4ac3 100644
--- a/annotate.el
+++ b/annotate.el
@@ -1601,7 +1601,7 @@ essentially what you get from:
           (message "Annotations saved.")))
        ((annotate-indirect-buffer-current-p)
         (annotate--dump-indirect-buffer file-annotations))
-       (t
+       (file-annotations
         (lwarn '(annotate-mode)
                :warning
                annotate-warn-buffer-has-no-valid-file

Reply via email to