Commit ac6a085a authored by catch's avatar catch

Issue #2684123 by dawehner: \Drupal\Core\Routing\RouteProvider::preLoadRoutes...

Issue #2684123 by dawehner: \Drupal\Core\Routing\RouteProvider::preLoadRoutes doens't handle the exception case correctly
parent 7236e50d
......@@ -207,13 +207,13 @@ public function preLoadRoutes($names) {
else {
try {
$result = $this->connection->query('SELECT name, route FROM {' . $this->connection->escapeTable($this->tableName) . '} WHERE name IN ( :names[] )', array(':names[]' => $routes_to_load));
$routes = $result->fetchAllKeyed();
$this->cache->set($cid, $routes, Cache::PERMANENT, ['routes']);
}
catch (\Exception $e) {
$result = [];
$routes = [];
}
$routes = $result->fetchAllKeyed();
$this->cache->set($cid, $routes, Cache::PERMANENT, ['routes']);
}
$this->serializedRoutes += $routes;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment