removed duplicate code
added pagination
fixed tests
fix case for empty tx list
added tests for pagination
Merge pull request #1750 from isocolsky/pagination

Pagination