Handle the case where the URL being encoded by qrcodejs is causing an error with the library (e.g. https://github.com/davidshimjs/qrcodejs/issues/78).

This commit is contained in:
Phil Elson 2021-10-06 11:55:27 +02:00
parent ea3f4abe0b
commit fcfaee2b4a

View file

@ -442,13 +442,15 @@
new QRCode(document.getElementById("qrcode"), {
text: "{{ permalink.shortened }}",
width: 330,
height: 330}
);
new QRCode(document.getElementById("pdf_qrcode"), {
height: 330,
correctLevel : QRCode.CorrectLevel.L
});
new QRCode(document.getElementById("pdf_qrcode"), {
text: "{{ permalink.shortened }}",
width: 133,
height: 133}
);
height: 133,
correctLevel : QRCode.CorrectLevel.L
});
</script>
</body>