Merge pull request #393 from budziq/playpen_errors
handle play.rust-lang.org communication errors in playpens
This commit is contained in:
commit
798225bcdc
|
@ -329,8 +329,12 @@ function run_rust_code(code_block) {
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
contentType: "application/json",
|
contentType: "application/json",
|
||||||
data: JSON.stringify(params),
|
data: JSON.stringify(params),
|
||||||
|
timeout: 15000,
|
||||||
success: function(response){
|
success: function(response){
|
||||||
result_block.text(response.result);
|
result_block.text(response.result);
|
||||||
}
|
},
|
||||||
|
error: function(qXHR, textStatus, errorThrown){
|
||||||
|
result_block.text("Playpen communication " + textStatus);
|
||||||
|
},
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue