# The safe eval function (use evalq to avoid searching in the current environment):
# [should use used directly in the code not as function call]
#.safe_eval <- function(x) evalq(x, env = .safe_env);
so replace all .safe_eval() by direct calls to evalq(CODE, env = .safe_env)
so replace all
.safe_eval()
by direct calls toevalq(CODE, env = .safe_env)
See the medication groups for a working example