summaryrefslogtreecommitdiffstats
path: root/etc/inc/voucher.inc
diff options
context:
space:
mode:
Diffstat (limited to 'etc/inc/voucher.inc')
-rw-r--r--etc/inc/voucher.inc14
1 files changed, 9 insertions, 5 deletions
diff --git a/etc/inc/voucher.inc b/etc/inc/voucher.inc
index b06e4d4..dc7f613 100644
--- a/etc/inc/voucher.inc
+++ b/etc/inc/voucher.inc
@@ -462,8 +462,16 @@ function voucher_configure($sync = false) {
if (is_array($config['voucher'])) {
foreach ($config['voucher'] as $voucherzone => $vcfg) {
+ if ($g['booting'])
+ echo gettext("Enabling voucher support... ");
$cpzone = $voucherzone;
- voucher_configure_zone($sync);
+ $error = voucher_configure_zone($sync);
+ if ($g['booting']) {
+ if ($error)
+ echo "error\n";
+ else
+ echo "done\n";
+ }
}
}
}
@@ -474,8 +482,6 @@ function voucher_configure_zone($sync = false) {
if (!isset($config['voucher'][$cpzone]['enable']))
return 0;
- if ($g['booting'])
- echo "Enabling voucher support... ";
if ($sync == true)
captiveportal_syslog("Writing voucher db from sync data...");
@@ -531,8 +537,6 @@ function voucher_configure_zone($sync = false) {
}
unlock($voucherlck);
- if ($g['booting'])
- echo "done\n";
}
return 0;
OpenPOWER on IntegriCloud