7275f269 by Ean Schuessler

#5167 remove callback once loaded

1 parent ba90b750
...@@ -10,6 +10,9 @@ define([], function() { ...@@ -10,6 +10,9 @@ define([], function() {
10 request.onreadystatechange = function() { 10 request.onreadystatechange = function() {
11 if (request.readyState == 3 || request.readyState == 4) { 11 if (request.readyState == 3 || request.readyState == 4) {
12 if (request.status == 200){ 12 if (request.status == 200){
13 if (request.onreadystatechange) {
14 request.onreadystatechange = null;
15 }
13 if (request.responseText) { 16 if (request.responseText) {
14 var newText = request.responseText.substr(responseLength); 17 var newText = request.responseText.substr(responseLength);
15 if (newText.length > 0) { 18 if (newText.length > 0) {
......