Big refactor! Removed unnecessary caching that was being performed by the custom layout
More refactoring and cleaning up