This pull should close #1057

Changed back to the initial check of window.EventSource, but with different log message