If multiple repositories exist and the same module exist in some of the repositories, the Find-Module command looks in all repositories and returns version as an array.
ensure changed ['4.9.0'] to 'System.Object[]' (corrective)
To fix this use Find-Module with the '-Repository' parameter
If multiple repositories exist and the same module exist in some of the repositories, the Find-Module command looks in all repositories and returns version as an array.
To fix this use Find-Module with the '-Repository' parameter
Thanks to @brajjan
Cloned from: https://github.com/hbuckle/puppet-powershellmodule/pull/28