When on the configuration page for the module, I was getting the following errors:

User error: "max" is an invalid render array key in Drupal\Core\Render\Element::children()
User error: "min" is an invalid render array key in Drupal\Core\Render\Element::children()

After digging around I think I found the issue in src/Form/UsajobsIntegrationConfigForm.php:

$form['filter_settings']['ResultsPerPage'] = [
      '#type' => 'number',
      '#title' => $this->t('Maximum Number of Results'),
      'min' => 1,
      'max' => 500,
      '#required' => FALSE,
      '#default_value' => $params->get('ResultsPerPage') ? $params->get('ResultsPerPage') : 10,
      '#description' => $this->t('The maximum number of Job Listings to display.'),
    ];

should be:

$form['filter_settings']['ResultsPerPage'] = [
      '#type' => 'number',
      '#title' => $this->t('Maximum Number of Results'),
      '#min' => 1,
      '#max' => 500,
      '#required' => FALSE,
      '#default_value' => $params->get('ResultsPerPage') ? $params->get('ResultsPerPage') : 10,
      '#description' => $this->t('The maximum number of Job Listings to display.'),
    ];

Comments

PCate created an issue. See original summary.

  • ericpugh committed 4bbf690 on 8.x-1.x
    Issue #3030143 by  PCate: 'min' and 'max' aren't valid render array keys...
ericpugh’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.