mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Make sure role name doesn't end up in task name more than once
Fixes #11691
This commit is contained in:
parent
b09f1f8e0b
commit
975172c1ef
1 changed files with 1 additions and 1 deletions
|
@ -97,7 +97,7 @@ class Task(Base, Conditional, Taggable, Become):
|
|||
def get_name(self):
|
||||
''' return the name of the task '''
|
||||
|
||||
if self._role and self.name:
|
||||
if self._role and self.name and not self.name.startswith("%s :" % self._role.get_name()):
|
||||
return "%s : %s" % (self._role.get_name(), self.name)
|
||||
elif self.name:
|
||||
return self.name
|
||||
|
|
Loading…
Reference in a new issue