luci-proto-openconnect: make PEM values optional

Fixes: #3191
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
Jo-Philipp Wich 2019-10-16 09:30:54 +02:00
parent 0321d47fe9
commit 7a010b1178

View file

@ -43,6 +43,9 @@ function validateCert(priv, section_id, value) {
start = false,
i;
if (value === null || value === '')
return true;
for (i = 0; i < lines.length; i++) {
if (lines[i].match(beg))
start = true;