From 9c5a4acf6046ad5b421412caf8a8748688a53830 Mon Sep 17 00:00:00 2001 From: Greg Sexton Date: Sat, 19 Apr 2014 15:02:51 +0100 Subject: [PATCH] Ensure default for previously open is t --- origami.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/origami.el b/origami.el index 76a2bcf..f958f76 100644 --- a/origami.el +++ b/origami.el @@ -365,9 +365,9 @@ consumed count." (defun origami-was-previously-open? (tree) (lambda (beg end) - (-> (origami-fold-find-node-with-range tree beg end) - -last-item - origami-fold-open-p))) + (-if-let (node (-last-item (origami-fold-find-node-with-range tree beg end))) + (origami-fold-open-p node) + t))) (defun origami-previous-data (tree) (lambda (beg end)