used string templating instead of regex templating