changes to storing and removing logic