با سلام و احترام
مشکلی که دارم اینکه یکی از خظوظ کدهای اسکریپت من در حالت دیباگ مرورگر کار میکنه


یه تابع دارم بدین صورت =>


function saveAccountGroup() {
if ($('#accgroupForm').valid()) {
$('#accgroupForm').ajaxSubmit({
cashe: false,
url: '/app/accountgroup/AddAccountGroup',
type: 'Post',
dataType: 'json',
data: $('#accgroupForm').serialize(),
success: function (result) {
if (!result.isError) {
loadaccountsfortree(false);
$('#resetForm').click();
cancleClick();
$('#dgAccountGroup').datagrid('reload');
swal(result.Msg, "", "success");
var rootnode = $('#jeAccountgroupsTree').tree('find', -1);
$('#jeAccountgroupsTree').tree('select', rootnode.target);
}
},
error: function (xhr, status) {
swal("خطای سیستم", result.Msg, "error");
}
});
} else {
setTimeout(function () {
$this.button('reset');
}, 8000);
return $(this).form('validate');
}
}



var rootnode = $('#jeAccountgroupsTree').tree('find', -1);
$('#jeAccountgroupsTree').tree('select', rootnode.target);



این دو خط کد فقط در حالت دیباگ مرورگر کار میکنه
این خطوط اجرا نمیشد رفتم در حالت دیباگ ببینم مشکل چیه و چه اکسپشنی میده که دیدم وقتی بریک پوینت میزارم کار میکنه !!!!!!!!!!!!!!!