mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-03 12:44:22 -07:00
Switch from using inspect to globals()
This commit is contained in:
parent
9bf33e56dd
commit
275be702a8
1 changed files with 1 additions and 2 deletions
|
@ -23,7 +23,6 @@ __metaclass__ = type
|
||||||
|
|
||||||
import glob
|
import glob
|
||||||
import imp
|
import imp
|
||||||
import inspect
|
|
||||||
import os
|
import os
|
||||||
import os.path
|
import os.path
|
||||||
import sys
|
import sys
|
||||||
|
@ -49,7 +48,7 @@ PLUGIN_PATH_CACHE = {}
|
||||||
|
|
||||||
|
|
||||||
def get_all_plugin_loaders():
|
def get_all_plugin_loaders():
|
||||||
return [(name, obj) for (name, obj) in inspect.getmembers(sys.modules[__name__]) if isinstance(obj, PluginLoader)]
|
return [(name, obj) for (name, obj) in globals().items() if isinstance(obj, PluginLoader)]
|
||||||
|
|
||||||
|
|
||||||
class PluginLoader:
|
class PluginLoader:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue