diff --git a/macao/assets/custom.js b/macao/assets/custom.js index 076c6c56cb6ff2035d358963c92d4931f527eb77..61f6bee100f9f23de1dca95bb01db090b5c11cb3 100644 --- a/macao/assets/custom.js +++ b/macao/assets/custom.js @@ -14,15 +14,17 @@ $(document).ready(function() { // Comment popover $('[spanid]').addClass('comment-trigger').each(function (){ const spanid = $(this).attr('spanid'); - console.log(spanid); - $(this).popover({ - trigger: 'click', - html: true, - placement: 'auto', - content: function () { - return $("[commentaireid=" + spanid + "]").html(); - } - }); + + if($("[commentaireid=" + spanid + "]").length !== 0) { + $(this).popover({ + trigger: 'click', + html: true, + placement: 'auto', + content: function () { + return $("[commentaireid=" + spanid + "]").html(); + } + }); + } }); $(document).on('click', function() { diff --git a/macao/themes/macao-hugo-theme b/macao/themes/macao-hugo-theme index a6970e449194b8568d9303f099ef591025180f58..b5ca12c7a576389bc20ad0d90bc4c106a4a1cbb6 160000 --- a/macao/themes/macao-hugo-theme +++ b/macao/themes/macao-hugo-theme @@ -1 +1 @@ -Subproject commit a6970e449194b8568d9303f099ef591025180f58 +Subproject commit b5ca12c7a576389bc20ad0d90bc4c106a4a1cbb6