This is fixed in XF 2.3 by virtue of the fact that the file no longer exists
The main reason for its inclusion on every page is because it's where the code for the cookie consent stuff lives. That now lives somewhere else in XF 2.3 so the only other notice related file that could get loaded (the carousel stuff) only loads if notices are enabled and there are any sliding notices.