[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/org 5bb699e0fd 2/2: org-babel-insert-result: Do not err
From: |
ELPA Syncer |
Subject: |
[elpa] externals/org 5bb699e0fd 2/2: org-babel-insert-result: Do not err when inline src block returns nil |
Date: |
Thu, 1 Sep 2022 09:58:15 -0400 (EDT) |
branch: externals/org
commit 5bb699e0fdef69fde5c7be6d010aa3a4dbb0418a
Author: Ihor Radchenko <yantar92@gmail.com>
Commit: Ihor Radchenko <yantar92@gmail.com>
org-babel-insert-result: Do not err when inline src block returns nil
* lisp/ob-core.el (org-babel-insert-result): Do not throw error when
src block returns nil or "".
Originally reported in
https://reddit.com/r/orgmode/comments/wy78gi/inline_noweb_or_some_way_to_use_src_block_results/imiw1b0/
---
lisp/ob-core.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lisp/ob-core.el b/lisp/ob-core.el
index c52ef9ed6e..0f7cc73c07 100644
--- a/lisp/ob-core.el
+++ b/lisp/ob-core.el
@@ -2329,8 +2329,8 @@ INFO may provide the values of these header arguments (in
the
(when inline
(let ((warning
(or (and (member "table" result-params) "`:results table'")
- (and (listp result) "list result")
- (and (string-match-p "\n." result) "multiline result")
+ (and result (listp result) "list result")
+ (and result (string-match-p "\n." result) "multiline result")
(and (member "list" result-params) "`:results list'"))))
(when warning
(user-error "Inline error: %s cannot be used" warning))))