mirror of
https://github.com/Icinga/icinga-powershell-framework.git
synced 2026-02-03 12:19:29 -05:00
18 lines
428 B
PowerShell
18 lines
428 B
PowerShell
function Test-IcingaCacheDataTempFile()
|
|
{
|
|
param (
|
|
[string]$Space,
|
|
[string]$CacheStore,
|
|
[string]$KeyName
|
|
);
|
|
|
|
# Once the file is written successully, validate it is fine
|
|
$tmpContent = Get-IcingaCacheData -Space $Space -CacheStore $CacheStore -KeyName $KeyName -TempFile;
|
|
|
|
if ($null -eq $tmpContent) {
|
|
# File is corrupt or empty
|
|
return $FALSE;
|
|
}
|
|
|
|
return $TRUE;
|
|
}
|