Problem/Motivation
We were getting a 'Deprecated function: substr() Passing null to parameter #1' error and I traced this back to line 65 of the domain_simple_sitemap.module file.
This line makes the assumption that if the domain_config module is installed the front page value can fetched from that config, in our case we had that module installed but the actual front page values are stored in the config for the domain_site_settings.
Steps to reproduce
Install both domain_config and domain_site_settings modules and configure the domain sites using the domain_site_settings config.
Proposed resolution
If domain_config is installed and fetch the config, if that config is empty fetch from domain_site_settings.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | domain_simple_sitemap-3460808-17.patch | 1.54 KB | omahm |
Issue fork domain_simple_sitemap-3460808
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
omahmUploaded patch of changes in fork
Comment #5
kevinvb commentedI had the same issue but with only the patch it didn't work because the value page.front can also be NULL while the configuration exists.
I added an additional check so if the configuration value is empty it doesn't throw the deprecation issue anymore.
Comment #6
kevinvb commentedComment #7
tim-dielsComment #10
i-trokhanenkoComment #12
i-trokhanenkoThanks!