Changed to my own code