protected function ReplicationActionForm::getDefaultSource in Deploy - Content Staging 8
Returns a source object.
Parameters
\Drupal\Core\Form\FormStateInterface $form_state: Form State values.
Return value
mixed The source object itself.
1 call to ReplicationActionForm::getDefaultSource()
- ReplicationActionForm::buildForm in src/
Form/ ReplicationActionForm.php - Implements buildForm().
File
- src/
Form/ ReplicationActionForm.php, line 256
Class
- ReplicationActionForm
- ReplicationActionForm class.
Namespace
Drupal\deploy\FormCode
protected function getDefaultSource(FormStateInterface $form_state) {
if (!empty($this->source)) {
return $this->source;
}
if (!empty($this
->getEntity($form_state)
->get('source')) && $this
->getEntity($form_state)
->get('source')->entity instanceof WorkspacePointerInterface) {
return $this->source = $this
->getEntity($form_state)
->get('source')->entity;
}
}