1
0
Fork 0
mirror of https://github.com/KingDuckZ/kamokan.git synced 2025-10-06 15:09:59 +00:00

Add a pastie_page mustache token.

This commit is contained in:
King_DuckZ 2017-06-19 15:45:56 +01:00
commit 17a5009f1f
3 changed files with 5 additions and 1 deletions

View file

@ -178,12 +178,14 @@ namespace kamokan {
statuslog->info("Sending response");
SPDLOG_TRACE(statuslog, "Preparing mustache dictionary");
const bool is_submit_page = this->is_submit_page();
const bool is_pastie_page = this->is_pastie_page();
mstch::map mustache_context {
{"submit_page", is_submit_page},
{"version", boost::string_view{STRINGIZE(VERSION_MAJOR) "." STRINGIZE(VERSION_MINOR) "." STRINGIZE(VERSION_PATCH)}},
{"tawashi_version", tawashi::version()},
{"base_uri", base_uri()},
{"host_path", make_host_path(this->settings())}
{"host_path", make_host_path(this->settings())},
{"pastie_page", is_pastie_page}
};
m_storage.finalize_connection();