add support for multiple substitutions