Updated loader to remove unnecessary variable