You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: no_negated_condition.rs
    path of file: ./repos/oxc/crates/oxc_linter/src/rules/unicorn
    
    the code of the file until where you have to start completion: use oxc_ast::{
    ast::{Expression, Statement},
    AstKind,
};
use oxc_diagnostics::{
    miette::{self, Diagnostic},
    thiserror::Error,
};
use oxc_macros::declare_oxc_lint;
use oxc_span::{GetSpan, Span};
use oxc_syntax::operator::{BinaryOperator, UnaryOperator};

use crate::{context::LintContext, rule::Rule, AstNode};

#[derive(Debug, Error, Diagnostic)]
#[error("eslint-plugin-unicorn(no-negated-condition): Unexpected negated condition.")]
#[diagnostic(
    severity(warning),
    help("Remove the negation operator and switch the consequent and alt
    
    fn run<'a>(&self, node: &AstNode<'a>, ctx: &LintContext<'a>) {
        let stmt_test = match node.kind() {
            AstKind::IfStatement(if_stmt) => {
                let Some(if_stmt_alternate) = &if_stmt.alternate else { return };

                if matches!(if_stmt_alternate, Statement::IfStatement(_)) {
                    return;
                }

                if_stmt.test.without_parenthesized()
            }
            AstKind::ConditionalExpression(conditional_expr) => {
                conditional_expr.test.without_parenthesized()
            }
            _ => {
                return;
            }
        };

        match stmt_test {
            Expression::UnaryExpression(unary_expr) => {
                if unary_expr.operator != UnaryOperator::LogicalNot {
                    return;
                }
            }
            Expression::BinaryExpression(binary_expr) => {
                if !matches!(
                    binary_expr.operator,
                    BinaryOperator::Inequality | BinaryOperator::StrictInequality
                ) {
                    return;
                }
            }
            _ => {
                return;
            }
        }

        ctx.diagnostic(NoNegatedConditionDiagnostic(stmt_test.span()));
    }