Apply suggestion from @pixeldesu

Co-authored-by: Andreas Nedbal <andy@pixelde.su>
This commit is contained in:
Karina Kwiatek 2022-01-09 18:34:19 +01:00 committed by Andreas Nedbal
parent d9e6982637
commit e7672e8033
1 changed files with 1 additions and 1 deletions

View File

@ -3,7 +3,7 @@ import closeAnnouncementHandler from './close';
export default (): void => {
registerEvents([
{ type: 'click', target: '.announcement button.close', handler: closeAnnouncementHandler, global: true },
{ type: 'click', target: document.querySelector('.announcement button.close'), handler: closeAnnouncementHandler },
]);
document.querySelectorAll('.announcement').forEach(function (el: HTMLDivElement) {