Fix error handling correctly when the target of delete_bucket doesn't exist