delete was handling arguments incorrectly