Perform additional refactoring to allow for attribute scanning to happen earlier