dealContentType.py 401 Bytes
# -*- coding: utf-8 -*-

# @Time    : 2021/7/16 14:51
# @Author  : Ljq
# @File    : dealContentType.py
# @Software: PyCharm

"""
    用于hearders中Content-Type格式处理
"""

def jsonCT(headers=None):
    headers["Content-Type"] = "application/json; charset=UTF-8"
    return headers

def urlCode(headers=None):
    headers["Content-Type"] = "application/x-www-form-urlencoded"
    return headers