improve next method