def _check_upload_response_headers(headers, body):
 if ('status' not in headers):
  try:
   d = jsonutils.loads(body)
   if (('image' in d) and ('status' in d['image'])):
    return
  except Exception:
   raise exception.UploadException(body)

def _check_upload_response_headers ( headers , body ) : if ( 'status' not in headers ) : try : d = jsonutils . loads ( body ) if ( ( 'image' in d ) and ( 'status' in d [ 'image' ] ) ) : return except Exception : raise exception . UploadException ( body )
check that the headers of an upload are reasonable .