mirror of
				https://github.com/NginxProxyManager/nginx-proxy-manager.git
				synced 2025-10-31 15:53:33 +00:00 
			
		
		
		
	Fixes formatting
This commit is contained in:
		| @@ -16,7 +16,7 @@ const letsencryptConfig  = '/etc/letsencrypt.ini'; | |||||||
| const certbotCommand     = 'certbot'; | const certbotCommand     = 'certbot'; | ||||||
| const archiver           = require('archiver'); | const archiver           = require('archiver'); | ||||||
| const path               = require('path'); | const path               = require('path'); | ||||||
| const { isArray } = require('lodash'); | const { isArray }        = require('lodash'); | ||||||
|  |  | ||||||
| function omissions() { | function omissions() { | ||||||
| 	return ['is_deleted']; | 	return ['is_deleted']; | ||||||
| @@ -1134,7 +1134,7 @@ const internalCertificate = { | |||||||
| 		} | 		} | ||||||
| 		 | 		 | ||||||
| 		// Create a test challenge file | 		// Create a test challenge file | ||||||
| 		const testChallengeDir = '/data/letsencrypt-acme-challenge/.well-known/acme-challenge'; | 		const testChallengeDir  = '/data/letsencrypt-acme-challenge/.well-known/acme-challenge'; | ||||||
| 		const testChallengeFile = testChallengeDir + '/test-challenge'; | 		const testChallengeFile = testChallengeDir + '/test-challenge'; | ||||||
| 		fs.mkdirSync(testChallengeDir, {recursive: true}); | 		fs.mkdirSync(testChallengeDir, {recursive: true}); | ||||||
| 		fs.writeFileSync(testChallengeFile, 'Success', {encoding: 'utf8'}); | 		fs.writeFileSync(testChallengeFile, 'Success', {encoding: 'utf8'}); | ||||||
|   | |||||||
| @@ -73,26 +73,26 @@ router | |||||||
|  * |  * | ||||||
|  * /api/nginx/certificates/test-http |  * /api/nginx/certificates/test-http | ||||||
|  */ |  */ | ||||||
|  router | router | ||||||
|  .route('/test-http') | 	.route('/test-http') | ||||||
|  .options((req, res) => { | 	.options((req, res) => { | ||||||
| 	 res.sendStatus(204); | 		res.sendStatus(204); | ||||||
|  }) | 	}) | ||||||
|  .all(jwtdecode()) | 	.all(jwtdecode()) | ||||||
|  |  | ||||||
| /** | /** | ||||||
|  * GET /api/nginx/certificates/test-http |  * GET /api/nginx/certificates/test-http | ||||||
|  * |  * | ||||||
|  * Test HTTP challenge for domains |  * Test HTTP challenge for domains | ||||||
|  */ |  */ | ||||||
|  .get((req, res, next) => { | 	.get((req, res, next) => { | ||||||
| 	 internalCertificate.testHttpsChallenge(res.locals.access, JSON.parse(req.query.domains)) | 		internalCertificate.testHttpsChallenge(res.locals.access, JSON.parse(req.query.domains)) | ||||||
| 		 .then((result) => { | 			.then((result) => { | ||||||
| 			 res.status(200) | 				res.status(200) | ||||||
| 				 .send(result); | 					.send(result); | ||||||
| 		 }) | 			}) | ||||||
| 		 .catch(next); | 			.catch(next); | ||||||
|  }); | 	}); | ||||||
|  |  | ||||||
| /** | /** | ||||||
|  * Specific certificate |  * Specific certificate | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user