API.edit(): fix handling of additional parameters