Foreach Loop Not Display All Entries

I created a custom function on my WordPress site that has a Gravity Form (GF) form on the site where people can pledge to create groups. There are 7 fields on the form (Form ID #1):

  1. Name
  2. Email
  3. Organization Name
  4. Organization Address
  5. # of Weekday Groups
  6. # of Weekend Groups
  7. Total # of Groups (hidden)

The script requests for the leads from GF form #1 and runs it through a foreach loop which keeps added the value from field 7 until there are no entries left.

However, starting today the code is only gathering 30 entries from the form when there are currently 60. Please help.

function test_gf(){
 $pledges = RGFormsModel::get_leads('1');   // Form_id
    $group_count = 0;   // resets group_count
    $entries = 0;
        foreach ($pledges as $pledge) {
            $group_count += $pledge[7]; // Adds each value from Field #7 (Total)
            $entries++; // Checking the number of entries processed

    // HTML Output
    echo '<h1>New Groups Pledged: '. $group_count . '</h1>' ;
    echo '<h2># of Entries Processed: '.$entries.'</h2>';


Exactly: $page_size=30, override this default value with bigger number:



 ? Get current month posts in Wordpress loop
 ? How can I remove the password confirmation field in Gravity Forms User Registration in Wordpress?
 ? PHP - How do I Add Exceptions or Exclude Pages, Sub Pages, or Objects from a "For Each" Loop?
 ? Gravity Forms User Registration
 ? wordpress Gravity forms bank account payment
 ? Wordpress Update User Function Timeout
 ? Wordpress Update User Function Timeout
 ? Wordpress Update User Function Timeout
 ? Wordpress Gravity Forms Serialized List
 ? How do I display the custom user meta fields I created in Gravity Forms User Registration?