fixing syntax error and bad arguments