CRL is read in as an array now, so even in the imported config it will appear to be an array even though it can only have one value. Fixes #1358

This commit is contained in:
jim-p 2011-04-06 13:36:24 -04:00
parent 6177fd924c
commit ab75b4ee54

View File

@ -1470,12 +1470,12 @@ function upgrade_051_to_052() {
$server['caref'] = $ca['refid'];
/* create a crl entry if needed */
if (!empty($server['crl'])) {
if (!empty($server['crl'][0])) {
$crl = array();
$crl['refid'] = uniqid();
$crl['descr'] = "Imported OpenVPN CRL #{$index}";
$crl['caref'] = $ca['refid'];
$crl['text'] = $server['crl'];
$crl['text'] = $server['crl'][0];
if(!is_array($config['crl']))
$config['crl'] = array();
$config['crl'][] = $crl;