From 5a3f73766c8eb063361f7f15471d8efe0fc404f9 Mon Sep 17 00:00:00 2001 From: lbesnard Date: Thu, 11 Jan 2024 06:25:16 +1100 Subject: [PATCH] Exporter: memos, replace space with underscore for # tag creation (#11107) Creating tags on memos looked like "#This is a book title" meaning only "#This" would become a Tag. Replacing spaces with underscore to be more usable so that the following tag would be created "#This_is_a_book_title" --- plugins/exporter.koplugin/target/memos.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/exporter.koplugin/target/memos.lua b/plugins/exporter.koplugin/target/memos.lua index 01ed6ec3b..f6521bb8b 100644 --- a/plugins/exporter.koplugin/target/memos.lua +++ b/plugins/exporter.koplugin/target/memos.lua @@ -135,7 +135,7 @@ function MemosExporter:createHighlights(booknotes) if clipping.note then highlight = highlight .. clipping.note .. "\n\n" end - highlight = highlight .. booknotes.title .. " (page: " .. clipping.page .. ")\n\n #" .. booknotes.title .. " #koreader" + highlight = highlight .. booknotes.title .. " (page: " .. clipping.page .. ")\n\n #" .. booknotes.title:gsub("%s+", "_") .. " #koreader" local result, err = makeRequest("POST", { content = highlight }, self.settings.api, self.settings.token) if not result then logger.warn("error creating highlights", err)