adding pagination to chat index action