On PHP 7.4, latest dev version throws the following error at /admin/config/search/simplesitemap as long as there is no sitemap present yet:

Notice: Undefined index: default in Drupal\simple_sitemap\Form\SimplesitemapSitemapsForm->buildForm() (line 156 of modules/contrib/simple_sitemap/src/Form/SimplesitemapSitemapsForm.php).
Drupal\simple_sitemap\Form\SimplesitemapSitemapsForm->buildForm(Array, Object)

Comments

extect created an issue. See original summary.

extect’s picture

Issue summary: View changes

  • gbyte.co committed 51d271a on 8.x-3.x
    Issue #3126793 by extect, gbyte.co: Notice: Undefined index in...
gbyte’s picture

Status: Active » Fixed

Fixed in dev.

Status: Fixed » Closed (fixed)

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

mlumadue’s picture

Reporting that the same issue turns up on 8.x-3.6 on PHP 7.2.30.

gbyte’s picture

@mlumadue Please don't, as it's been fixed already. Feel free to check out the dev version.

AlexBorsody’s picture

I am using "drupal/simple_sitemap": "^3.9", and getting a similar error. Fresh install on a relatively fresh D9 site. PHP 7.4.

Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'main.simple_sitemap' doesn't exist: SELECT type, status FROM {simple_sitemap} GROUP BY type, status; Array ( ) in Drupal\simple_sitemap\Form\SimplesitemapSitemapsForm->fetchSitemapInstanceStatuses() (line 203 of /app/web/modules/contrib/simple_sitemap/src/Form/SimplesitemapSitemapsForm.php).