Bug 17855: Redirect to the installer if installation process is not done yet
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Mon, 17 Apr 2017 15:16:17 +0000 (12:16 -0300)
committerKyle M Hall <kyle@bywatersolutions.com>
Fri, 28 Apr 2017 12:36:20 +0000 (08:36 -0400)
Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
installer/onboarding.pl

index ca62726..943def7 100755 (executable)
@@ -18,6 +18,7 @@
 # along with Koha; if not, see <http://www.gnu.org/licenses>.
 
 use Modern::Perl;
+use C4::Context;
 use C4::InstallAuth;
 use CGI qw ( -utf8 );
 use C4::Output;
@@ -36,6 +37,11 @@ use Koha::IssuingRules;
 my $input = new CGI;
 my $step  = $input->param('step');
 
+unless ( C4::Context->preference('Version') ) {
+    print $input->redirect("/cgi-bin/koha/installer/install.pl");
+    exit;
+}
+
 #Getting the appropriate template to display to the user
 my ( $template, $loggedinuser, $cookie ) =
   C4::InstallAuth::get_template_and_user(