Fix secure() function editing

This commit is contained in:
Gregory Schier
2025-10-21 20:09:56 -07:00
parent 28bb460409
commit 7e2d72c4e3
3 changed files with 21 additions and 5 deletions

View File

@@ -78,6 +78,10 @@ pub fn template_function_secure_run<R: Runtime>(
_ => return Ok("".to_string()),
};
if value.is_empty() {
return Ok("".to_string());
}
let value = match value.strip_prefix("YENC_") {
None => {
return Err(RenderError("Could not decrypt non-encrypted value".to_string()));