del middleware; fix delete method