Default statistics module. Count views of only published nodes when administration users see it I need to change default functionality of statistics module.

I want to count views of only published nodes by administration users too. I can't find any hook for this.

Now if administration user see unpublished node, counter is increased.

Is this possible without hacking a core?
The Statistics module doesn't use any hook because generally works when Drupal has not completed its bootstrap phase. (That is if caching pages is enabled.)

What you can do is creating a custom module that runs right after the Statistics module, and execute code similar to the following one.

function mymodule_exit() {
  global $user;

  drupal_bootstrap(DRUPAL_BOOTSTRAP_VARIABLES);
  $is_node = (arg(0) == 'node' &amp;&amp; is_numeric(arg(1)) &amp;&amp; arg(2) == NULL);

  if (variable_get('statistics_count_content_views', 0) &amp;&amp; $is_node) {
    drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
    $node = node_load(arg(1));
    if (!$node-&gt;status) {
      db_merge('node_counter')
        -&gt;key(array('nid' =&gt; $node-&gt;nid))
        -&gt;fields(array(
          'daycount' =&gt; 1, 
          'totalcount' =&gt; 1, 
          'timestamp' =&gt; REQUEST_TIME,
        ))
        -&gt;expression('daycount', 'daycount - 1')
        -&gt;expression('totalcount', 'totalcount - 1')
        -&gt;execute();
    }
  }
  if (variable_get('statistics_enable_access_log', 0) &amp;&amp; $is_node) {
    drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
    $node = node_load(arg(1));    
    if (!$node-&gt;status) {
      db_delete('accesslog')
        -&gt;condition('title' =&gt; truncate_utf8(strip_tags(drupal_get_title()), 255))
        -&gt;condition('path' =&gt; truncate_utf8($_GET['q'], 255))
        -&gt;condition('url' =&gt; isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '')
        -&gt;condition('hostname' =&gt; ip_address())
        -&gt;condition('uid' =&gt; $user-&gt;uid)
        -&gt;condition('sid' =&gt; session_id()) 
        -&gt;condition('timestamp' =&gt; REQUEST_TIME)
        -&gt;execute();
    }
  }
}