Issue #2094335 by andypost: Statistics.php needs a lower bootstrap level.
parent
2e6c6d71e7
commit
9aa21496ae
|
@ -97,4 +97,5 @@ class StatisticsLoggingTest extends WebTestBase {
|
|||
$node_counter = statistics_get($this->node->id());
|
||||
$this->assertIdentical($node_counter['totalcount'], '1');
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -11,12 +11,12 @@ chdir('../../..');
|
|||
// Load the Drupal bootstrap.
|
||||
require_once dirname(dirname(__DIR__)) . '/vendor/autoload.php';
|
||||
require_once dirname(dirname(__DIR__)) . '/includes/bootstrap.inc';
|
||||
drupal_bootstrap(DRUPAL_BOOTSTRAP_PAGE_CACHE);
|
||||
drupal_bootstrap(DRUPAL_BOOTSTRAP_KERNEL);
|
||||
|
||||
if (\Drupal::config('statistics.settings')->get('count_content_views')) {
|
||||
$nid = filter_input(INPUT_POST, 'nid', FILTER_VALIDATE_INT);
|
||||
if ($nid) {
|
||||
db_merge('node_counter')
|
||||
\Drupal::database()->merge('node_counter')
|
||||
->key(array('nid' => $nid))
|
||||
->fields(array(
|
||||
'daycount' => 1,
|
||||
|
|
Loading…
Reference in New Issue