i write a try catch block in my java code,but i found that in some
situation the catch part will not take effect after been compiled to
javascript,and in some situation do.
i wondered why?
for example:
/////////////////////////////////////////////
try{
if(){
// do sth.
}
}
} catch (Exception e) {
// do sth2;
}
/////////////////////////////////////////////
do sth2 will not work,then i modified it to :
/////////////////////////////////////////////
try{
if(){
// do sth.
}
else{
// do another thing;
}
}
} catch (Exception e) {
// do sth2;
}
/////////////////////////////////////////////
now it works