Fixed threading issue in RestSQLAction