Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / lib / Drupal / Core / Theme / ThemeInitialization.php
index 0067ee8710aedea0897382635ffdc5942672d285..5d429dd799a25d851669d918fccc4a52ac73a884 100644 (file)
@@ -173,6 +173,15 @@ class ThemeInitialization implements ThemeInitializationInterface {
     $values['path'] = $theme_path;
     $values['name'] = $theme->getName();
 
+    // Use the logo declared in this themes info file, otherwise use logo.svg
+    // from the themes root.
+    if (!empty($theme->info['logo'])) {
+      $values['logo'] = $theme->getPath() . '/' . $theme->info['logo'];
+    }
+    else {
+      $values['logo'] = $theme->getPath() . '/logo.svg';
+    }
+
     // @todo Remove in Drupal 9.0.x.
     $values['stylesheets_remove'] = $this->prepareStylesheetsRemove($theme, $base_themes);