Elisp newbie here,
I am trying to filter MS safelinks from an org-mode icalendar event, which gets saved by the
gnus-icalendar:org-event-save function. I have created a function that filters the MS safelinks and am now trying to apply it to the buffer created inside
gnus-icalendar:org-event-save. I have tried unsuccessfully to 1) run it as a hook, and 2) re-define the function as
(defun gnus-icalendar:org-event-save (event reply-status) (with-temp-buffer (org-capture-string (gnus-icalendar-event->org-entry event reply-status) gnus-icalendar-org-template-key) (unsafelinks nil)))
When I have MS safelinks in
*scratch* and eval
(unsafelinks nil) the links get filtered, so I don't understand why the above setup doesn't work. Probably it is an obvious mistake from someone learning elisp. Thank you in advance.
Per request of wasamasa, the text to be filtered out is returned by the function
(gnus-icalendar-event->org-entry event reply-status).