Fixed single entity return bug for pagination and wrote appropriate test
Merge branch 'DS-1203'
Merge branch 'master' into DS-1008