update&deletes unneeded resources