diff options
-rw-r--r-- | src/plugins/lua/multimap.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/plugins/lua/multimap.lua b/src/plugins/lua/multimap.lua index 252c592ff..60324fac1 100644 --- a/src/plugins/lua/multimap.lua +++ b/src/plugins/lua/multimap.lua @@ -210,6 +210,14 @@ local function apply_url_filter(task, filter, url, r) return nil end end + elseif string.find(filter, '^template:') then + if not r['template'] then + r['template'] = string.match(filter, '^template:(.+)') + end + + if r['template'] then + return lua_util.template(r['template'], url:to_table()) + end end return url:get_host() |