From ca02fd1b0cf4c38621aa4a44feddf688554ae090 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Mon, 25 Jul 2016 18:38:18 +0200 Subject: Add single alias function --- init.lua | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'init.lua') diff --git a/init.lua b/init.lua index 80d510d..233019b 100644 --- a/init.lua +++ b/init.lua @@ -90,6 +90,11 @@ function doc.add_entry_aliases(category_id, entry_id, aliases) end end +-- Same as above, but only adds one alias +function doc.add_entry_alias(category_id, entry_id, alias) + doc.data.categories[category_id].entry_aliases[alias] = entry_id +end + --[[ Functions for internal use ]] function doc.formspec_core(tab) -- cgit v1.2.3