Execution of a new rule in workflow is looping when array 'Commands' in template is empty

Change-Id: I403ad174bf6917cdb36fd363efd00ed9402aba45
Merge "Execution of a new rule in workflow is looping when array 'Commands' in template is empty" into release-0.3