(#8319) Fix macports provider when ensure is latest but the package is not present
The query method is expected to return an array but could return nil if a
package was not present. Make sure it just returns an empty array in that
case.
Signed-off-by: Patrick Carlisle <patrick@puppetlabs.com>