protected function DiskSpaceValidator::stat in Automatic Updates 8.2
Wrapper around the stat() function.
Parameters
string $path: The path to check.
Return value
array The statistics for the path.
Throws
\RuntimeException If the statistics could not be determined.
1 call to DiskSpaceValidator::stat()
- DiskSpaceValidator::areSameLogicalDisk in src/
Validator/ DiskSpaceValidator.php - Checks if two paths are located on the same logical disk.
File
- src/
Validator/ DiskSpaceValidator.php, line 74
Class
- DiskSpaceValidator
- Validates that there is enough free disk space to do automatic updates.
Namespace
Drupal\automatic_updates\ValidatorCode
protected function stat(string $path) : array {
$stat = stat($path);
if ($stat === FALSE) {
throw new \RuntimeException("Cannot get information for {$path}.");
}
return $stat;
}