Varun/n+1queries

This solves the n+1 queries, but there will be some queries that will be eagerly loaded when they shouldn't be.