Dotclear


Ignore:
Timestamp:
09/18/18 20:22:10 (7 years ago)
Author:
franck <carnet.franck.paul@…>
Branch:
default
Message:

Use let and const rather than var (ES2015/ES6), use template string where is more efficient

File:
1 edited

Legend:

Unmodified
Added
Removed
  • plugins/pings/js/post.js

    r3709 r3880  
    33 
    44$(function() { 
    5      $('#edit-entry').onetabload(function() { 
    6           if ($('p.ping-services').length > 0) { 
    7                var p = $('<p></p>'); 
    8                p.addClass('ping-services'); 
    9                $('p.ping-services:last').after(p); 
    10                dotclear.checkboxesHelpers($('p.ping-services:last').get(0), $('.check-ping-services')); 
    11           } 
    12           $('h5.ping-services').toggleWithLegend($('p.ping-services'),{ 
    13                user_pref: 'dcx_ping_services', 
    14                legend_click: true 
    15           }); 
    16      }); 
     5  $('#edit-entry').onetabload(function() { 
     6    if ($('p.ping-services').length > 0) { 
     7      const p = $('<p></p>'); 
     8      p.addClass('ping-services'); 
     9      $('p.ping-services:last').after(p); 
     10      dotclear.checkboxesHelpers($('p.ping-services:last').get(0), $('.check-ping-services')); 
     11    } 
     12    $('h5.ping-services').toggleWithLegend($('p.ping-services'), { 
     13      user_pref: 'dcx_ping_services', 
     14      legend_click: true 
     15    }); 
     16  }); 
    1717}); 
Note: See TracChangeset for help on using the changeset viewer.

Sites map