refact global part4