fix more warnings
use nextBatch instead of next