repaired check_weixin_legality