mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-09 18:45:54 +02:00
ovpnmain.cgi: Load all modules at the beginning
Although Perl modules tend to take a long time to load, it is better to do this at the beginning so that loading the script will show any errors. Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
@@ -23,6 +23,9 @@
|
||||
###
|
||||
use CGI;
|
||||
use CGI qw/:standard/;
|
||||
use Imager::QRCode;
|
||||
use MIME::Base32;
|
||||
use MIME::Base64;
|
||||
use Net::DNS;
|
||||
use Net::Ping;
|
||||
use Net::Telnet;
|
||||
@@ -2638,9 +2641,6 @@ else
|
||||
} elsif ($cgiparams{'ACTION'} eq $Lang::tr{'show otp qrcode'}) {
|
||||
&General::readhasharray("${General::swroot}/ovpn/ovpnconfig", \%confighash);
|
||||
|
||||
use MIME::Base32;
|
||||
use MIME::Base64;
|
||||
use Imager::QRCode;
|
||||
my $qrcode = Imager::QRCode->new(
|
||||
size => 6,
|
||||
margin => 0,
|
||||
|
||||
Reference in New Issue
Block a user