Skip to content

Commit 7b7f40b

Browse files
author
Brent Cook
committed
remove modules that cannot be instantiated
1 parent 0caeee3 commit 7b7f40b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/msf/core/module_set.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ def create(reference_name)
5757
# Notify any general subscribers of the creation event
5858
if instance
5959
self.framework.events.on_module_created(instance)
60+
else
61+
self.delete(reference_name)
6062
end
6163

6264
return instance

0 commit comments

Comments
 (0)