Update with Ma Weiqi's commit