Skip to content

Commit 5fd9aff

Browse files
committed
Fix regression that reversed copy the content of files: Revert "Update the module's function to reflect the script's changes"
This reverts commit 130122b.
1 parent 600da69 commit 5fd9aff

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/script/Compile-SourceScript.ps1

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ function Compile-SourceScript {
5252
)
5353

5454
begin {
55+
"Starting Compile-SourceScript" | Write-Host -ForegroundColor Cyan
5556
$ErrorActionPreference = 'Stop'
5657
$MOD = @{
5758
sourcemod = @{
@@ -155,7 +156,9 @@ function Compile-SourceScript {
155156
$compiledDirItemsDiff = if ($compiledDirItemsPost) {
156157
if ($compiledDirItemsPre) {
157158
$hashesDiffObj = Compare-object -ReferenceObject $compiledDirItemsPre -DifferenceObject $compiledDirItemsPost -Property FullName, md5 | ? { $_.SideIndicator -eq '=>' }
158-
$compiledDirItemsPost | ? { $_.md5 -in $hashesDiffObj.md5 }
159+
if ($hashesDiffObj) {
160+
$compiledDirItemsPost | ? { $_.md5 -in $hashesDiffObj.md5 }
161+
}
159162
}else {
160163
$compiledDirItemsPost
161164
}

0 commit comments

Comments
 (0)