File tree Expand file tree Collapse file tree 4 files changed +7
-9
lines changed
app/nginx/certificates/list Expand file tree Collapse file tree 4 files changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -343,7 +343,6 @@ const internalCertificate = {
343343 * @returns {Promise }
344344 */
345345 download : ( access , data ) => {
346-
347346 return new Promise ( ( resolve , reject ) => {
348347 access . can ( 'certificates:get' , data )
349348 . then ( ( ) => {
@@ -366,8 +365,6 @@ const internalCertificate = {
366365 fileName : opName
367366 } ;
368367 resolve ( resp ) ;
369- } ) . catch ( ( err ) => {
370- reject ( err ) ;
371368 } ) ;
372369 } else {
373370 throw new error . ValidationError ( 'Only Let\'sEncrypt certificates can be renewed' ) ;
@@ -377,10 +374,10 @@ const internalCertificate = {
377374 } ,
378375
379376 /**
380- * @param {String } source
381- * @param {String } out
382- * @returns {Promise }
383- */
377+ * @param {String } source
378+ * @param {String } out
379+ * @returns {Promise }
380+ */
384381 zipDirectory ( source , out ) {
385382 const archive = archiver ( 'zip' , { zlib : { level : 9 } } ) ;
386383 const stream = fs . createWriteStream ( out ) ;
Original file line number Diff line number Diff line change 4141 < span class = " dropdown-header" >< %- i18n (' audit-log' , ' certificate' ) % > #< %- id % >< / span>
4242 < % if (provider === ' letsencrypt' ) { % >
4343 < a href= " #" class = " renew dropdown-item" >< i class = " dropdown-icon fe fe-refresh-cw" >< / i> < %- i18n (' certificates' , ' force-renew' ) % >< / a>
44- < a href= " #" class = " download dropdown-item" >< i class = " dropdown-icon fe fe-download" >< / i>< %- i18n (' certificates' , ' download' ) % >< / a>
44+ < a href= " #" class = " download dropdown-item" >< i class = " dropdown-icon fe fe-download" >< / i> < %- i18n (' certificates' , ' download' ) % >< / a>
4545 < div class = " dropdown-divider" >< / div>
4646 < % } % >
4747 < a href= " #" class = " delete dropdown-item" >< i class = " dropdown-icon fe fe-trash-2" >< / i> < %- i18n (' str' , ' delete' ) % >< / a>
Original file line number Diff line number Diff line change @@ -31,6 +31,7 @@ module.exports = Mn.View.extend({
3131 let win = window . open ( $ ( e . currentTarget ) . attr ( 'rel' ) , '_blank' ) ;
3232 win . focus ( ) ;
3333 } ,
34+
3435 'click @ui.download' : function ( e ) {
3536 e . preventDefault ( ) ;
3637 App . Api . Nginx . Certificates . download ( this . model . get ( 'id' ) )
Original file line number Diff line number Diff line change 188188 "other-certificate-key" : " Certificate Key" ,
189189 "other-intermediate-certificate" : " Intermediate Certificate" ,
190190 "force-renew" : " Renew Now" ,
191- "download" :" Download" ,
191+ "download" : " Download" ,
192192 "renew-title" : " Renew Let'sEncrypt Certificate"
193193 },
194194 "access-lists" : {
You can’t perform that action at this time.
0 commit comments