onddo/dovecot-cookbook — pull request #6 by kampfschlaefer (2014-03-06 08:56:22+00:00)
Title: Auth-definitions below ldap are a hash, not an array

While using this cookbook to set up a dovecot authenticating against an AD I wondered the following didn't make it install dovecot-ldap (I like using symbols in my recipes):
```ruby
node.default[:dovecot][:auth][:ldap][:passdb][:args] = '/etc/dovecot/dovecot-ldap.conf.ext'
node.default[:dovecot][:auth][:ldap][:userdb][:args] = '/etc/dovecot/dovecot-ldap.conf.ext'
```
This patch fixes this.

The patch could even be simplified by writing
```ruby
only_if node['dovecot']['auth'].fetch('ldap', {}).length > 0
```