title: 'dict object' has no attribute 'stdout' in Ansible Playbook
body: <p>My playbook:</p>
  
  <pre><code>- name: JBoss KeyStore and Truststore passwords will be stored in the          password vault
      #shell: less "{{ vault }}"
       shell: cat "{{ vault }}"
      register: vault_contents
      tags:
        - BW.6.1.1.10
      with_items:
        - "{{ vault }}"
    - debug:
         msg: "JBoss config filedoes not contains the word vault"
      when: vault_contents.stdout.find('$VAULT') == -1
  </code></pre>
  
  <p>I'm trying to read multiple files through ansible using Jinga2 Template and parse the output as stdout and search for a keyword and report it.</p>
  
  <p>It fails with the below error:</p>
  
  <pre><code>TASK [testing_roles : debug]   **************************************************************************.   *****************************************************************
  fatal: [d84e4fe137f4]: FAILED! =&gt; {"failed": true, "msg": "The conditional check 'vault_contents.stdout.find('$VAULT') == -1' failed. 
  The error was: error while evaluating conditional (vault_contents.stdout.find('$VAULT') == -1): 'dict object' has no attribute 'stdout'\n\nThe error appears to have been in '/Ansible/Ansible/Relearn/testing_roles/roles/testing_roles/tasks/main.yml': line 49, column 5, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n      - \"{{ vault }}\"\n  - debug:\n    ^ here\n"}
  to retry, use: --limit @/Ansible/Ansible/Relearn/testing_roles/playbook.retry
  </code></pre>
  
  <p>When i append it with a single file entry it works as expected but when it is changes to a series of files it fails.</p>
  
  <p>Is this the right approach to scan multiple files in Ansible or should be be using some other module or method.</p>
  
  <p>Any help is greatly appreciated.</p>
  
  <p>In the vars file it has the below contents:</p>
  
  <pre><code>vault:
    - /jboss-as-7.1.1.Final/standalone/configuration/standalone-full-ha.xml
  </code></pre>
  
  <p>Thank you</p>