mergeDefaults() protected method

Returns all of the index options set to their default or given value (using the given options).
protected mergeDefaults ( array $opts ) : [String
$opts array
return [String
 /**
  * Returns all of the index options set to their default or given value (using the given options).
  * @param [String => mixed] $opts Index options.
  * @return [String => mixed]
  */
 protected function mergeDefaults(array $opts)
 {
     // Merges with defaults.
     $opts = parent::mergeDefaults($opts);
     // Converts types.
     $opts['active'] = $this->convertToBoolean($opts['active']);
     $opts['voided'] = $this->convertToBoolean($opts['voided']);
     $opts['related_agents'] = $this->convertToBoolean($opts['related_agents']);
     $opts['related_activities'] = $this->convertToBoolean($opts['related_activities']);
     $opts['attachments'] = $this->convertToBoolean($opts['attachments']);
     $opts['ascending'] = $this->convertToBoolean($opts['ascending']);
     $opts['limit'] = $this->convertToInt($opts['limit']);
     $opts['offset'] = $this->convertToInt($opts['offset']);
     if ($opts['limit'] === 0) {
         $opts['limit'] = 100;
     }
     return $opts;
 }