Commit 575723b0 authored by rockyl's avatar rockyl

修改curse命名错误

parent c04f01a9
......@@ -12,12 +12,19 @@ const https = require('https');
let publicPath;
function handler(request, response){
function handler(request, response) {
return serveHandler(request, response, {
public: publicPath,
headers: {
'Access-Control-Allow-Origin': '*',
}
headers: [
{
source: '**/*',
headers: [
{
key: 'Access-Control-Allow-Origin', value: '*',
}
]
}
]
});
}
......@@ -28,11 +35,11 @@ exports.start = function (options) {
publicPath = path.resolve(folder);
if (fs.existsSync(publicPath)) {
let sslOpts;
if(keyFile && certFile){
if (keyFile && certFile) {
const keyContent = fs.readFileSync(keyFile, 'utf8'),
certContent = fs.readFileSync(certFile, 'utf8');
if(keyContent && certContent){
if (keyContent && certContent) {
sslOpts = {
key: keyContent,
cert: certContent
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment