Skip to content

Commit fbf8e7f

Browse files
committed
Minor bug fix to --file-read
1 parent decab66 commit fbf8e7f

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

plugins/generic/filesystem.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,10 @@ def readFile(self, rFile):
289289

290290
for chunk in fileContent:
291291
if isinstance(chunk, (list, tuple, set)):
292-
chunk = chunk[0]
292+
if len(chunk) > 0:
293+
chunk = chunk[0]
294+
else:
295+
chunk = ""
293296

294297
newFileContent += chunk
295298

0 commit comments

Comments
 (0)