public function MarkdownCommands::__construct in Markdown 8.2
MarkdownCommands constructor.
Parameters
\Drupal\Core\File\FileSystemInterface $fileSystem: The File System service.
\Psr\Log\LoggerInterface $logger: A Logger.
File
- src/
Commands/ MarkdownCommands.php, line 99
Class
- MarkdownCommands
- Markdown commands for Drush 9+.
Namespace
Drupal\markdown\CommandsCode
public function __construct(FileSystemInterface $fileSystem, LoggerInterface $logger) {
parent::__construct();
$this->fileSystem = $fileSystem;
$this->logger = $logger;
if (!static::$shutdownRegistered) {
drupal_register_shutdown_function(function () {
foreach (static::$tempDirs as $tempDir) {
$this->fileSystem
->deleteRecursive($tempDir);
}
});
static::$shutdownRegistered = TRUE;
}
}