Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
mechatroner committed Nov 11, 2019
1 parent 40864ce commit a23a3de
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions test/library_demos/table_based.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,18 @@
let output_table = [];
let user_query = document.getElementById('query_input').value;
clear_html_table(document.getElementById('dst_table'));
let error_handler = function(error_type, error_msg) {
alert('RBQL Query finished with error: ' + error_type + ': ' + error_msg);

let error_handler = function(exception) {
alert('RBQL Query finished with error: ' + String(exception));
}

let success_handler = function(warnings) {
if (warnings.length)
alert('Warnings: ' + warnings.join('\n'))
write_html_table(output_table, document.getElementById('dst_table'));
}
rbql.table_run(user_query, input_table, output_table, success_handler, error_handler);

rbql.table_run(user_query, input_table, output_table).then(success_handler).catch(error_handler);
}

document.addEventListener("DOMContentLoaded", function(event) {
Expand Down

0 comments on commit a23a3de

Please sign in to comment.