Certificates polish
This commit is contained in:
@ -1,15 +1,11 @@
|
||||
'use strict';
|
||||
|
||||
const _ = require('lodash');
|
||||
const error = require('../lib/error');
|
||||
const proxyHostModel = require('../models/proxy_host');
|
||||
const redirectionHostModel = require('../models/redirection_host');
|
||||
const deadHostModel = require('../models/dead_host');
|
||||
|
||||
const internalHost = {
|
||||
|
||||
allowed_ssl_files: ['certificate', 'certificate_key', 'intermediate_certificate'],
|
||||
|
||||
/**
|
||||
* Internal use only, checks to see if the domain is already taken by any other record
|
||||
*
|
||||
@ -66,21 +62,6 @@ const internalHost = {
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* Cleans the ssl keys from the meta object and sets them to "true"
|
||||
*
|
||||
* @param {Object} meta
|
||||
* @returns {*}
|
||||
*/
|
||||
cleanMeta: function (meta) {
|
||||
internalHost.allowed_ssl_files.map(key => {
|
||||
if (typeof meta[key] !== 'undefined' && meta[key]) {
|
||||
meta[key] = true;
|
||||
}
|
||||
});
|
||||
return meta;
|
||||
},
|
||||
|
||||
/**
|
||||
* Private call only
|
||||
*
|
||||
|
Reference in New Issue
Block a user