fixing lagging time issue