found a bug in the function structure where when the same parameter is referenced multiple times, the value gets overridden in the argumnents map.