tidy up the completed function
now not passing along the complete button, check for the form name instead