wasnt actually updating the value in the struct