remove trailing commas in arguments hash