def _get_body(http_msg):
    """Private method that gets the body/content of a request/response.

    Args:
        http_msg [requests.models.PreparedRequest / requests.models.Response]:
        the request or the response that has information to be hidden.

    Returns:
        [bytes]: the body/content of the request/response.
    """
    if not hasattr(http_msg, "body"):
        return http_msg._content

    return http_msg.body