mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 09:23:56 +00:00
Fix case where __virtulname__ falls back to True
This commit is contained in:
parent
cf32d4e55b
commit
7577520ad8
@ -1114,7 +1114,8 @@ class Loader(object):
|
|||||||
|
|
||||||
# If the __virtual__ function returns True and __virtualname__ is set then use it
|
# If the __virtual__ function returns True and __virtualname__ is set then use it
|
||||||
elif virtual is True and virtualname != module_name:
|
elif virtual is True and virtualname != module_name:
|
||||||
module_name = getattr(mod, '__virtualname__', virtual)
|
if virtualname is not True:
|
||||||
|
module_name = virtualname
|
||||||
|
|
||||||
except KeyError:
|
except KeyError:
|
||||||
# Key errors come out of the virtual function when passing
|
# Key errors come out of the virtual function when passing
|
||||||
|
Loading…
Reference in New Issue
Block a user