Removed duplication of querying for class and user pages