Skip to content

Commit

Permalink
Fixed exception when FilePatcherJson.Dependencies is null
Browse files Browse the repository at this point in the history
  • Loading branch information
evandixon committed Dec 10, 2016
1 parent ed4d290 commit 949d67f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion DS ROM Patcher/FilePatcher.vb
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,13 @@ Public Class FilePatcher
End Function

Public Sub CopyToolsToDirectory(newToolsDir As String)
For Each item In SerializableInfo.Dependencies.Concat({SerializableInfo.CreatePatchProgram, SerializableInfo.ApplyPatchProgram}).Distinct
Dim tools As New List(Of String)
If SerializableInfo.Dependencies IsNot Nothing
tools.AddRange(SerializableInfo.Dependencies)
End If
tools.Add(SerializableInfo.CreatePatchProgram)
tools.Add(SerializableInfo.ApplyPatchProgram)
For Each item In tools.Distinct
Dim source As String = Path.Combine(ToolsDirectory, item)
Dim dest As String = Path.Combine(newToolsDir, item)

Expand Down

0 comments on commit 949d67f

Please sign in to comment.