Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
neoki07 committed Jun 5, 2024
1 parent 984731a commit f1e27dd
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use biome_analyze::{
};
use biome_console::markup;
use biome_css_syntax::{AnyCssDeclarationName, CssGenericProperty, CssLanguage, CssSyntaxKind};
use biome_rowan::{AstNode, Language, SyntaxNode, SyntaxNodeCast, TextRange, WalkEvent};
use biome_rowan::{AstNode, Language, SyntaxNode, TextRange, WalkEvent};

use crate::utils::{get_longhand_sub_properties, get_reset_to_initial_properties, vender_prefix};

Expand Down Expand Up @@ -102,9 +102,7 @@ impl Visitor for NoDeclarationBlockShorthandPropertyOverridesVisitor {
self.prior_props_in_block.clear();
}
CssSyntaxKind::CSS_GENERIC_PROPERTY => {
if let Some(prop_node) = node
.clone()
.cast::<CssGenericProperty>()
if let Some(prop_node) = CssGenericProperty::cast_ref(node)
.and_then(|property_node| property_node.name().ok())
{
let prop = prop_node.text();
Expand Down

0 comments on commit f1e27dd

Please sign in to comment.