Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit 4f0bc1a

Browse files
committed
Typo
1 parent 255ba69 commit 4f0bc1a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

crates/ide-diagnostics/src/handlers/unresolved_field.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,12 +95,12 @@ fn add_field_fix(ctx: &DiagnosticsContext<'_>, d: &hir::UnresolvedField) -> Opti
9595
add_field_to_struct_fix(ctx, adt_struct, field_name, suggested_type, error_range)
9696
}
9797
Adt::Union(adt_union) => {
98-
add_varient_to_union(ctx, adt_union, field_name, suggested_type, error_range)
98+
add_variant_to_union(ctx, adt_union, field_name, suggested_type, error_range)
9999
}
100100
_ => None,
101101
}
102102
}
103-
fn add_varient_to_union(
103+
fn add_variant_to_union(
104104
ctx: &DiagnosticsContext<'_>,
105105
adt_union: Union,
106106
field_name: &str,
@@ -121,7 +121,7 @@ fn add_varient_to_union(
121121
let mut src_change_builder = SourceChangeBuilder::new(range.file_id);
122122
src_change_builder.insert(offset, record_field);
123123
Some(vec![Assist {
124-
id: AssistId("add-varient-to-union", AssistKind::QuickFix),
124+
id: AssistId("add-variant-to-union", AssistKind::QuickFix),
125125
label: Label::new("Add field to union".to_owned()),
126126
group: None,
127127
target: error_range.range,

0 commit comments

Comments
 (0)