mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-25 03:41:25 -07:00
Add a base-level get_basedir method for lookup plugins and fix relative lookups
Fixes #11746
This commit is contained in:
parent
3a4dd523d3
commit
ee835ff7ad
5 changed files with 14 additions and 15 deletions
|
@ -45,12 +45,9 @@ class LookupModule(LookupBase):
|
|||
if isinstance(terms, basestring):
|
||||
terms = [ terms ]
|
||||
|
||||
ret = []
|
||||
basedir = self.get_basedir(variables)
|
||||
|
||||
if 'role_path' in variables:
|
||||
basedir = variables['role_path']
|
||||
else:
|
||||
basedir = self._loader.get_basedir()
|
||||
ret = []
|
||||
|
||||
for term in terms:
|
||||
params = term.split()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue