public function WSServer::enable in Web Service Data 2.0.x
Same name and namespace in other branches
- 8 src/Entity/WSServer.php \Drupal\wsdata\Entity\WSServer::enable()
Enables the configuration entity.
Return value
$this
Overrides ConfigEntityBase::enable
1 call to WSServer::enable()
- WSServer::isDisabled in src/
Entity/ WSServer.php - Check if wsserver is disabled.
File
- src/
Entity/ WSServer.php, line 166
Class
- WSServer
- Defines the Web Service Server entity.
Namespace
Drupal\wsdata\EntityCode
public function enable($degraded = FALSE) {
unset($this->state['degraded']);
unset($this->state['disabled']);
$reason = '';
if ($degraded) {
$reason = ' ' . t('Automatically re-enabling previously degrated service.');
}
\Drupal::logger('wsdata')
->notice(t('WSConfig Type %label (%type) was enabled.', [
'%label' => $this
->label(),
'%type' => $this->wsconnector,
]) . $reason);
}