mirror of
https://github.com/github/codeql.git
synced 2025-12-17 01:03:14 +01:00
C#: Use StringBuilder for feed arguments in GetRestoreArgs
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
using Newtonsoft.Json.Linq;
|
using Newtonsoft.Json.Linq;
|
||||||
|
|
||||||
using Semmle.Util;
|
using Semmle.Util;
|
||||||
@@ -71,10 +71,13 @@ namespace Semmle.Extraction.CSharp.DependencyFetching
|
|||||||
// the configuration file(s).
|
// the configuration file(s).
|
||||||
if (restoreSettings.Sources != null)
|
if (restoreSettings.Sources != null)
|
||||||
{
|
{
|
||||||
|
var feedArgs = new StringBuilder();
|
||||||
foreach (string source in restoreSettings.Sources)
|
foreach (string source in restoreSettings.Sources)
|
||||||
{
|
{
|
||||||
args += $" -s {source}";
|
feedArgs.Append($" -s {source}");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
args += feedArgs.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (restoreSettings.ForceReevaluation)
|
if (restoreSettings.ForceReevaluation)
|
||||||
|
|||||||
Reference in New Issue
Block a user