Fixed errors with script for repeating parameters