fixed some bugs, changed MERGE to VIAMAIL