Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 3383B200C8A for ; Sun, 4 Jun 2017 16:47:07 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 32478160BE3; Sun, 4 Jun 2017 14:47:07 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 77116160BB7 for ; Sun, 4 Jun 2017 16:47:06 +0200 (CEST) Received: (qmail 97035 invoked by uid 500); 4 Jun 2017 14:47:05 -0000 Mailing-List: contact commits-help@ponymail.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ponymail.incubator.apache.org Delivered-To: mailing list commits@ponymail.incubator.apache.org Received: (qmail 97026 invoked by uid 99); 4 Jun 2017 14:47:05 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 04 Jun 2017 14:47:05 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 4B24C182883 for ; Sun, 4 Jun 2017 14:47:05 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -4.222 X-Spam-Level: X-Spam-Status: No, score=-4.222 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id SbTsgG1pCw0Q for ; Sun, 4 Jun 2017 14:47:04 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with SMTP id A67F55F2AB for ; Sun, 4 Jun 2017 14:47:03 +0000 (UTC) Received: (qmail 97018 invoked by uid 99); 4 Jun 2017 14:47:02 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 04 Jun 2017 14:47:02 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id C6F2BDFB94; Sun, 4 Jun 2017 14:47:02 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: humbedooh@apache.org To: commits@ponymail.incubator.apache.org Date: Sun, 04 Jun 2017 14:47:02 -0000 Message-Id: <02e1a7bf2d8f48ab942ff187ae03c65a@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [1/3] incubator-ponymail git commit: remove redundant counting archived-at: Sun, 04 Jun 2017 14:47:07 -0000 Repository: incubator-ponymail Updated Branches: refs/heads/master c58b23127 -> 5d9f505b7 remove redundant counting Project: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/commit/33d68285 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/tree/33d68285 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/diff/33d68285 Branch: refs/heads/master Commit: 33d682850d79879d1c588256db5941ed9330d8e3 Parents: c58b231 Author: Daniel Gruno Authored: Sun Jun 4 16:41:34 2017 +0200 Committer: Daniel Gruno Committed: Sun Jun 4 16:41:34 2017 +0200 ---------------------------------------------------------------------- site/api/stats.lua | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-ponymail/blob/33d68285/site/api/stats.lua ---------------------------------------------------------------------- diff --git a/site/api/stats.lua b/site/api/stats.lua index c2ddee3..0c14932 100644 --- a/site/api/stats.lua +++ b/site/api/stats.lua @@ -567,8 +567,6 @@ function handle(r) dhh = doc.hits.hits end - local h = 0 - -- Debug time point 5 if DEBUG then table.insert(t, r:clock() - tnow) @@ -581,8 +579,6 @@ function handle(r) local email = v._source if aaa.canAccessDoc(r, email, account) then - h = h + 1 - local eml = utils.extractCanonEmail(email.from) local gravatar = r:md5(eml:lower()) email.gravatar = gravatar @@ -737,7 +733,7 @@ function handle(r) listdata.lastMonth = datespan.lastMonth listdata.list = listraw:gsub("^([^.]+)%.", "%1@"):gsub("[<>]+", "") listdata.emails = emls - listdata.hits = h + listdata.hits = #emls listdata.searchlist = listraw listdata.participants = top10 listdata.cloud = cloud