Removing unused keys