From #2452637: Remove function system_rebuild_theme_data() from system.module

Function is still in use in ThemeSettingsInfo.php which provokes a PHP Fatal error
(drupal8-beta9)

CommentFileSizeAuthor
#4 2460437-4.patch666 bytesmarthinal
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

kiwad’s picture

This should fix it

- $this->data = system_rebuild_theme_data();
+ $this->data = \Drupal::service('theme_handler')->rebuildThemeData();

mbrett5062’s picture

I did the following and it worked.

- $this->data = system_rebuild_theme_data();
+ $this->data = \Drupal::state()->get('system.theme.data', array());

Taken straight from latest (04/11/2015) Drupal 8 Dev. In the following file.

core\includes\module.inc (Line 36)

mbrett5062’s picture

Actually, just checked and the code from @kiwad in #1 is the correct way to go.

marthinal’s picture

Component: Miscellaneous » Theme Generator
Status: Active » Needs review
FileSize
666 bytes

Patch attached :)

kae76’s picture

This patch worked (2460437-4.patch), haven't received any errors since.

Thanks

Jeff Burnz’s picture

Assigned: Unassigned » Jeff Burnz

OK, good catch, lets get this tested and committed asap. Cheers.

Jeff Burnz’s picture

Status: Needs review » Fixed

Thank you for the patch and reviews, committed!

Status: Fixed » Closed (fixed)

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