function Message::getMessageFromFile
Same name in other branches
- 8.9.x composer/Plugin/ProjectMessage/Message.php \Drupal\Composer\Plugin\ProjectMessage\Message::getMessageFromFile()
- 10 composer/Plugin/ProjectMessage/Message.php \Drupal\Composer\Plugin\ProjectMessage\Message::getMessageFromFile()
- 11.x composer/Plugin/ProjectMessage/Message.php \Drupal\Composer\Plugin\ProjectMessage\Message::getMessageFromFile()
Reads the message file as an array.
Parameters
string $file: The file to read. Relative paths are relative to the project directory.
Return value
string[]
1 call to Message::getMessageFromFile()
- Message::getText in composer/
Plugin/ ProjectMessage/ Message.php
File
-
composer/
Plugin/ ProjectMessage/ Message.php, line 112
Class
- Message
- Determine configuration.
Namespace
Drupal\Composer\Plugin\ProjectMessageCode
protected function getMessageFromFile($file) {
return file_exists($file) ? file($file, FILE_IGNORE_NEW_LINES) : [];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.