Merge pull request #37639 from rallytime/bp-37607

Back-port #37607 to 2016.3
This commit is contained in:
Mike Place 2016-11-12 09:29:20 +13:00 committed by GitHub
commit 7510cd4da9

View file

@ -77,6 +77,7 @@ from __future__ import absolute_import
import atexit
import logging
import time
from salt.ext.six.moves.http_client import BadStatusLine # pylint: disable=E0611
# Import Salt Libs
from salt.exceptions import SaltSystemExit
@ -440,7 +441,14 @@ def get_mors_with_properties(service_instance, object_type, property_list=None,
rootFolder.
'''
# Get all the content
content = get_content(service_instance, object_type, property_list=property_list, container_ref=container_ref)
content_args = [service_instance, object_type]
content_kwargs = {'property_list': property_list,
'container_ref': container_ref,
}
try:
content = get_content(*content_args, **content_kwargs)
except BadStatusLine:
content = get_content(*content_args, **content_kwargs)
object_list = []
for obj in content: