Conditions | 1 |
Paths | 1 |
Total Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
19 | public static function createForSingleMonitor(array $monitorConfig): Collection |
||
20 | { |
||
21 | return collect($monitorConfig['disks'])->map(function ($diskName) use ($monitorConfig) { |
||
22 | $backupDestination = BackupDestination::create($diskName, $monitorConfig['name']); |
||
23 | |||
24 | return (new BackupDestinationStatus($backupDestination, $diskName, static::buildInspections($monitorConfig))) |
||
25 | ->setMaximumAgeOfNewestBackupInDays($monitorConfig['newestBackupsShouldNotBeOlderThanDays']) |
||
26 | ->setMaximumStorageUsageInMegabytes($monitorConfig['storageUsedMayNotBeHigherThanMegabytes']); |
||
27 | }); |
||
28 | } |
||
29 | |||
42 |