brought back removeObject but with guard