mirror of
https://github.com/asdlokj1qpi233/subconverter.git
synced 2026-11-03 02:02:24 +00:00
Fix incorrect argument count for find in template
Add managed_config_prefix to global variables in template.
This commit is contained in:
2 files changed
+2
-1
No files matched your search
+1
-1
@@ -50,7 +50,7 @@ int render_template(const std::string &content, const template_args &vars, std::
|
||||
std::string data = args.at(0)->get<std::string>();
|
||||
return trim(data);
|
||||
});
|
||||
m_callbacks.add_callback("find", 1, [](inja::Arguments &args)
|
||||
m_callbacks.add_callback("find", 2, [](inja::Arguments &args)
|
||||
{
|
||||
std::string src = args.at(0)->get<std::string>(), target = args.at(1)->get<std::string>();
|
||||
return regFind(src, target);
|
||||
|
||||
Reference in new issue
Block a user