Skip to content

Commit

Permalink
Only add the id if not null fix #1152
Browse files Browse the repository at this point in the history
  • Loading branch information
AmauriC committed Oct 17, 2023
1 parent 4bbd5e7 commit e8d2044
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tarteaucitron.js
Original file line number Diff line number Diff line change
Expand Up @@ -1908,7 +1908,9 @@ var tarteaucitron = {
}
} else {
script = document.createElement('script');
script.id = (id !== undefined) ? id : '';
if (id !== undefined) {
script.id = id;
}
script.async = true;
script.src = url;

Expand Down

0 comments on commit e8d2044

Please sign in to comment.