diff --git a/crates/oxc_linter/src/rules/typescript/no_this_alias.rs b/crates/oxc_linter/src/rules/typescript/no_this_alias.rs index 35eae1326b00b..5e7a18ab8ddce 100644 --- a/crates/oxc_linter/src/rules/typescript/no_this_alias.rs +++ b/crates/oxc_linter/src/rules/typescript/no_this_alias.rs @@ -31,7 +31,7 @@ fn no_this_destructure_diagnostic(span: Span) -> OxcDiagnostic { #[derive(Debug, Default, Clone)] pub struct NoThisAlias(Box); -#[derive(Debug, Clone)] +#[derive(Debug, Default, Clone)] pub struct NoThisAliasConfig { allow_destructuring: bool, allow_names: FxHashSet, @@ -45,11 +45,6 @@ impl std::ops::Deref for NoThisAlias { } } -impl Default for NoThisAliasConfig { - fn default() -> Self { - Self { allow_destructuring: true, allow_names: FxHashSet::default() } - } -} impl NoThisAlias { fn is_allowed(&self, name: &str) -> bool { self.allow_names.contains(name) diff --git a/crates/oxc_linter/tests/rule_configuration_test.rs b/crates/oxc_linter/tests/rule_configuration_test.rs index e068399285a53..9b3a90284d8aa 100644 --- a/crates/oxc_linter/tests/rule_configuration_test.rs +++ b/crates/oxc_linter/tests/rule_configuration_test.rs @@ -24,11 +24,7 @@ fn test_rule_default_matches_from_configuration_null() { // When fixing a rule, ensure that either: // 1. The Default implementation returns the same values as from_configuration(null), or // 2. The from_configuration method is updated to return Default::default() when given null - let exceptions = [ - "typescript/no-this-alias", - "unicorn/prefer-object-from-entries", - "unicorn/prefer-structured-clone", - ]; + let exceptions = ["unicorn/prefer-object-from-entries", "unicorn/prefer-structured-clone"]; // Iterate through all available linter rules for rule in RULES.iter() {