hal.py 文件源码

python
阅读 32 收藏 0 点赞 0 评论 0

项目:chaos-monkey-engine 作者: BBVA 项目源码 文件源码
def __init__(self, **kwargs):
        """Initialises a new ``Self`` link instance. Accepts the same
        Keyword Arguments as :class:`.Link`.

        Additional Keyword Args:
            external (bool): if true, force link to be fully-qualified URL, defaults to False

        See Also:
            :class:`.Link`
        """

        url = request.url
        external = kwargs.get('external', False)
        if not external and current_app.config['SERVER_NAME'] is None:
            url = request.url.replace(request.host_url, '/')

        return super(Self, self).__init__('self', url, **kwargs)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号