facil.io icon indicating copy to clipboard operation
facil.io copied to clipboard

fiobj_mustache.c: No folder argument

Open dertuxmalwieder opened this issue 3 years ago • 1 comments

From the source code:

/**
 * Loads a mustache template, converting it into an opaque instruction array.
 *
 * Returns a pointer to the instruction array.
 *
 * The `folder` argument should contain the template's root folder which would
 * also be used to search for any required partial templates.
 *
 * The `filename` argument should contain the template's file name.
 */
mustache_s *fiobj_mustache_load(fio_str_info_s filename) {
  return mustache_load(.filename = filename.data, .filename_len = filename.len);
}

There is no folder argument.

dertuxmalwieder avatar Dec 15 '21 12:12 dertuxmalwieder

Hi @dertuxmalwieder ,

Thank you for opening this issue.

Yes, you are right, the folder information is extracted automatically from the filename. While the API has been updated, the documentation lagged behind.

I'll get to it when I have a bit more time.

Thanks!

Cheers, Bo.

boazsegev avatar Dec 19 '21 07:12 boazsegev