From ca52300bd0efe5a3081d36ef2c8068ab31d39df8 Mon Sep 17 00:00:00 2001
From: Paudet <philippe.audet-fortin@inlibro.com>
Date: Thu, 10 Aug 2017 15:45:26 -0400
Subject: [PATCH] Bug 11317: (Follow-up) Fixing merge error and cosmetic
 changes

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
---
 koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc         | 3 +++
 koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt | 1 -
 koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt     | 2 +-
 tools/access_files.pl                                           | 2 +-
 4 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc
index 50e52f7..67783e2 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc
+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc
@@ -108,4 +108,7 @@
     [% IF ( CAN_user_tools_upload_general_files ) %]
        <li><a href="/cgi-bin/koha/tools/upload.pl">Upload any file</a></li>
     [% END %]
+    [% IF ( CAN_user_tools_access_files ) %]
+    <li><a href="/cgi-bin/koha/tools/access_files.pl">Report/log files</a></li>
+    [% END %]
 </ul></div></div>
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt
index e243062..557b16c 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt
@@ -68,7 +68,6 @@
 		<li><a href="/cgi-bin/koha/reports/issues_avg_stats.pl">Average loan time</a></li>
         <li><a href="http://schema.koha-community.org/" target="blank">Koha database schema</a></li>
         <li><a href="http://wiki.koha-community.org/wiki/SQL_Reports_Library" target="blank">Koha reports library</a></li>
-        <li><a href="/cgi-bin/koha/tools/access_files.pl">Report/log files</a></li>
         <!--<li><a href="/cgi-bin/koha/reports/stats.screen.pl">Till reconciliation</a></li> -->
 	</ul></div>
 </div>
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt
index 6aa69ed..da1884b 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt
@@ -116,7 +116,7 @@
 
     [% IF CAN_user_tools_access_files %]
     <dt><a href="/cgi-bin/koha/tools/access_files.pl">Report/log files</a></dt>
-    <dd>Report/log files</dd>
+    <dd>Access report or log files</dd>
     [% END %]
 
 </dl>
diff --git a/tools/access_files.pl b/tools/access_files.pl
index 20aeb4c..0fb57af 100755
--- a/tools/access_files.pl
+++ b/tools/access_files.pl
@@ -96,7 +96,7 @@ else {
         }
         close $fh;
 
-        exit(1);
+        exit(0);
     }
     else{
         # Send the file list to the template
-- 
2.1.4