Browse Source

fix for js + async = false

Nicolas Cannasse 16 years ago
parent
commit
7c6725f89a
1 changed files with 2 additions and 1 deletions
  1. 2 1
      std/haxe/Http.hx

+ 2 - 1
std/haxe/Http.hx

@@ -122,7 +122,8 @@ class Http {
 				me.onError("Http Error #"+r.status);
 			}
 		};
-		r.onreadystatechange = onreadystatechange;
+		if( async )
+			r.onreadystatechange = onreadystatechange;
 		var uri = postData;
 		if( uri != null )
 			post = true;