fixed some bugs for release of dart.
a "cross" function