updating method