added pagination, some issues with the queue still