public function next($data, $form)
    {
        // Save the form data for the current step
        $this->save($form->getData());

        // Get the next step class
        $nextStepClass = $this->getCurrentStep()->getNextStep();

        if (!$nextStepClass) {
            $this->controller->redirectBack();
            return false;
        }

        // Perform custom step validation (use MultiFormStep->getValidator() for
        // built-in functionality). The data needs to be manually saved on error
        // so the form is re-populated.
        if (!$this->getCurrentStep()->validateStep($data, $form)) {
            $this->getRequest()->getSession()->set("FormInfo.{$form->FormName()}.data", $form->getData());
            $this->controller->redirectBack();
            return false;
        }

        // validation succeeded so we reset it to remove errors and messages
        $this->clearFormState();

        // Determine whether we can use a step already in the DB, or have to create a new one
        if (!$nextStep = DataObject::get_one($nextStepClass, "\"SessionID\" = {$this->session->ID}")) {
            $nextStep = Injector::inst()->create($nextStepClass);
            $nextStep->SessionID = $this->session->ID;
            $nextStep->write();
        }

        // Set the next step found as the current step
        $this->setCurrentStep($nextStep);

        // Redirect to the next step
        $this->controller->redirect($nextStep->Link());
    }