Thanks, Raad!
I'll go over your suggestion in more detail later today but I wanted to answer your question - the code for creating new communities has already been modified. The problem was that the code for cloning communities was initially overlooked, so some communities have now been created that don't have the permissions set correctly. My goal here is to fix those, and then all will be happy. :)