Fix https://github.com/opscode-cookbooks/samba/pull/6, some refactorings don't turn out well