support 5.1
change code places