Skip to content

Commit e05bbb0

Browse files
committed
C#: Fix always-null bug in TRAP writer
1 parent 9e73ed7 commit e05bbb0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

csharp/extractor/Semmle.Extraction/TrapWriter.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ private void ArchiveContents(string fullInputPath, string contents)
285285
public static string NestPaths(ILogger logger, string outerpath, string innerpath, InnerPathComputation innerPathComputation)
286286
{
287287
string nested = innerpath;
288-
if (outerpath != null || outerpath.Length != 0)
288+
if (!string.IsNullOrEmpty(outerpath))
289289
{
290290
if (!Path.IsPathRooted(innerpath) && innerPathComputation == InnerPathComputation.ABSOLUTE)
291291
innerpath = Path.GetFullPath(innerpath);

0 commit comments

Comments
 (0)