public function LegacyMessenger::deleteMessagesByType in Service Container 7
Same name and namespace in other branches
- 8 src/Messenger/LegacyMessenger.php \Drupal\service_container\Messenger\LegacyMessenger::deleteMessagesByType()
- 7.2 src/Messenger/LegacyMessenger.php \Drupal\service_container\Messenger\LegacyMessenger::deleteMessagesByType()
Deletes all messages of a certain type.
Parameters
string $type: The messages' type. Either self::STATUS, self::WARNING, or self::ERROR.
Return value
$this
Overrides MessengerInterface::deleteMessagesByType
File
- src/
Messenger/ LegacyMessenger.php, line 68 - Contains \Drupal\service_container\LegacyMessenger.
Class
- LegacyMessenger
- Class that manage the messages in Drupal.
Namespace
Drupal\service_container\MessengerCode
public function deleteMessagesByType($type) {
$this->drupal7
->drupal_get_messages($type, TRUE);
return $this;
}