change code 2 be portable