Automattic\WooCommerce\Internal\Admin\Logging\FileV2
File::create
Create and set permissions on the file.
Метод класса: File{}
Хуков нет.
Возвращает
true|false.
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->create(): bool;
Код File::create() File::create WC 10.3.4
protected function create(): bool {
try {
$filesystem = FilesystemUtil::get_wp_filesystem();
$created = $filesystem->touch( $this->path );
$modded = $filesystem->chmod( $this->path );
} catch ( Exception $exception ) {
return false;
}
return $created && $modded;
}