Removed some dead logic