Made the change more elegant

As suggested by @hosseinsh. This is of course more elegant.
This commit is contained in:
sirferl 2020-02-16 09:28:52 +01:00 committed by GitHub
parent a70a49e4e9
commit 1815c89970
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 3 deletions

View File

@ -101,9 +101,7 @@ def process_options(options):
# if there is a config variable with VERISIGN_PRODUCT_<upper(authority.name)> take the value as Cert product-type
# else default to "Server", to be compatoible with former versions
authority = options.get("authority").name.upper()
product_type = current_app.config.get("VERISIGN_PRODUCT_{0}".format(authority))
if product_type is None:
product_type = "Server"
product_type = current_app.config.get("VERISIGN_PRODUCT_{0}".format(authority), "Server")
data = {
"challenge": get_psuedo_random_string(),
"serverType": "Apache",