Skip to content

Commit 524402a

Browse files
committed
Land rapid7#7762, nil fix for generic/custom
2 parents afd8315 + 29d6cf4 commit 524402a

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

modules/payloads/singles/generic/custom.rb

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,12 @@ def generate
4242
self.arch = actual_arch
4343
end
4444

45-
if datastore['PAYLOADFILE']
46-
IO.read(datastore['PAYLOADFILE'])
47-
elsif datastore['PAYLOADSTR']
45+
if datastore['PAYLOADSTR']
4846
datastore['PAYLOADSTR']
47+
elsif datastore['PAYLOADFILE']
48+
IO.read(datastore['PAYLOADFILE'])
49+
else
50+
''
4951
end
5052
end
5153

0 commit comments

Comments
 (0)