Skip to content

Commit ec1619e

Browse files
author
Kinneyzhang
committed
update
1 parent 63b58c6 commit ec1619e

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

tp.el

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -968,14 +968,16 @@ NEW-OBJECT is the new string object (only different for strings with tp-text)."
968968
((stringp tp-text-val)
969969
;; Apply transform if layer has one registered
970970
(let* ((layer-name (plist-get props 'tp-name))
971-
(transform-fn (when layer-name (cdr (assoc layer-name tp-layer-transforms))))
972-
(final-text (if transform-fn
973-
(condition-case err
974-
(funcall transform-fn tp-text-val)
975-
(error
976-
(message "tp: transform error for %s: %s" layer-name err)
977-
tp-text-val))
978-
tp-text-val)))
971+
(transform-fn (when layer-name
972+
(cdr (assoc layer-name tp-layer-transforms))))
973+
(final-text
974+
(if transform-fn
975+
(condition-case err
976+
(funcall transform-fn tp-text-val)
977+
(error
978+
(message "tp: transform error for %s: %s" layer-name err)
979+
tp-text-val))
980+
tp-text-val)))
979981
(if (stringp object)
980982
;; For strings: create a new string with tp-text content
981983
;; The new string replaces the original, with props applied

0 commit comments

Comments
 (0)