Skip to content

Commit

Permalink
Merge pull request #413 from dylan8902/pub-thursday-audit
Browse files Browse the repository at this point in the history
More data
  • Loading branch information
dylan8902 authored Feb 20, 2024
2 parents 82fc618 + b72cfd5 commit fce64f3
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions app/controllers/pub_thursday_audit_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,16 @@ def index
response = JSON.parse(RestClient.get(url).body)
documents.concat response["documents"]

url = "#{url}&pageToken=#{response["nextPageToken"]}"
response = JSON.parse(RestClient.get(url).body)
next_page = "#{url}&pageToken=#{response["nextPageToken"]}"
response = JSON.parse(RestClient.get(next_page).body)
documents.concat response["documents"]

next_page = "#{url}&pageToken=#{response["nextPageToken"]}"
response = JSON.parse(RestClient.get(next_page).body)
documents.concat response["documents"]

next_page = "#{url}&pageToken=#{response["nextPageToken"]}"
response = JSON.parse(RestClient.get(next_page).body)
documents.concat response["documents"]

documents.each do |session|
Expand Down

0 comments on commit fce64f3

Please sign in to comment.