Browse Source

Update file message.js

mayx 5 months ago
parent
commit
4ee425d47c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Live2dHistoire/live2d/js/message.js

+ 1 - 1
Live2dHistoire/live2d/js/message.js

@@ -189,7 +189,7 @@ if (!norunFlag) {
 		if (Array.isArray(text)) text = text[Math.floor(Math.random() * text.length + 1) - 1];
 		//console.log('showMessage', text);
 		$('.message').stop();
-		if (text instanceof EventSource) {
+		if (typeof EventSource !== 'undefined' && text instanceof EventSource) {
 			var outputContainer = $('.message')[0];
 			var eventFlag = false;
 			text.onmessage = function(event) {