def METHOD_NAME():
    if not request.endpoint:
        return
    if should_skip_redirect_on_insecure_password(request.endpoint):
        return
    if 'insecure_password_error' not in session:
        return
    if request.method != 'GET':
        raise NoReportError.wrap_exc(Forbidden(_('You need to change your password')))
    if request.is_xhr or request.is_json:
        return
    return redirect(url_for('auth.accounts'))