changed ready function 3