No longer send application/json-patch+json as Content-Type

The Content-Type required for patch in the API has changed. Use the
new type

Change-Id: If7bb84330a96a692f834d51abc1ce1f0de359751
This commit is contained in:
Craig Bryant 2015-02-11 17:38:15 -07:00
parent 7ebcad8c5c
commit 3df8be47dc
2 changed files with 2 additions and 6 deletions

View File

@ -219,11 +219,7 @@ class HTTPClient(object):
def json_request(self, method, url, **kwargs):
kwargs.setdefault('headers', {})
if method == "PATCH":
kwargs['headers'].setdefault('Content-Type',
'application/json-patch+json')
else:
kwargs['headers'].setdefault('Content-Type', 'application/json')
kwargs['headers'].setdefault('Content-Type', 'application/json')
kwargs['headers'].setdefault('Accept', 'application/json')
if 'data' in kwargs:

View File

@ -86,7 +86,7 @@ class MonascaShell(object):
'prepended with the private key.')
parser.add_argument('--key-file',
help='Path of client key to use in SSL connection.'
help='Path of client key to use in SSL connection. '
'This option is not necessary if your key is'
' prepended to your cert file.')