Closed nyanginator closed 6 years ago
hhmm, thanks @nyanginator,
I've just had a deeper look and it seems like the issue is that this just isn't standard js, it should not be var element = event.srcElement;
it should be var element = event.target;
https://developer.mozilla.org/en/docs/Web/API/Event/srcElement
https://developer.mozilla.org/en-US/docs/Web/API/Event/target
thanks @nyanginator I've just pushed an alternate fixed for this so I'll close this pr, sorry for the misdirection
Added check for null element to avoid "TypeError: element is undefined" error (in Firefox) as discussed in https://github.com/brendanheywood/moodle-local_cleanurls/issues/97