AUI-1450 Fixing for the case when paginator is not defined
AUI-1450 Adding tests
AUI-1450 - Source formatting