Skip to content
Snippets Groups Projects
Commit 103c0adf authored by pancho's avatar pancho Committed by Liam Morland
Browse files

Issue #3040903 by Pancho, Liam Morland: Create fillpdf_template_scheme()

parent 2c5c88e0
No related branches found
No related tags found
No related merge requests found
...@@ -2070,6 +2070,18 @@ function fillpdf_scheme_options() { ...@@ -2070,6 +2070,18 @@ function fillpdf_scheme_options() {
return $options; return $options;
} }
/**
* Returns the configured template scheme for FillPDF.
*
* Template files are less sensitive, so if the configured FillPDF template
* scheme is unavailable, we may fall back to the system's file default scheme.
*/
function fillpdf_template_scheme() {
$template_scheme = variable_get('fillpdf_scheme');
$scheme_options = fillpdf_scheme_options();
return $template_scheme && isset($scheme_options[$template_scheme]) ? $template_scheme : variable_get('file_default_scheme', 'public');
}
/** /**
* Returns the default scheme for PDF files populated by FillPDF. * Returns the default scheme for PDF files populated by FillPDF.
* *
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment