Skip to content

Commit 1ed473a

Browse files
committed
Fix formatting
1 parent 128775d commit 1ed473a

File tree

2 files changed

+9
-11
lines changed

2 files changed

+9
-11
lines changed

crates/oxide/src/extractor/arbitrary_property_machine.rs

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -235,12 +235,12 @@ impl Machine for ArbitraryPropertyMachine<ParsingValueState> {
235235
// otherwise its invalid
236236
Class::Exclamation if self.bracket_stack.is_empty() => {
237237
if cursor.input[cursor.pos..].starts_with(b"!important]") {
238-
cursor.advance_by(10);
238+
cursor.advance_by(10);
239239

240-
return self.done(self.start_pos, cursor);
240+
return self.done(self.start_pos, cursor);
241241
}
242242

243-
return self.restart()
243+
return self.restart();
244244
}
245245

246246
// Everything else is valid
@@ -384,10 +384,8 @@ mod tests {
384384
"[background:url(https://example.com?q={[{[([{[[2]]}])]}]})]",
385385
vec!["[background:url(https://example.com?q={[{[([{[[2]]}])]}]})]"],
386386
),
387-
388387
// A property containing `!` at the top-level is invalid
389388
("[color:red!]", vec![]),
390-
391389
// Unless its part of `!important at the end
392390
("[color:red!important]", vec!["[color:red!important]"]),
393391
] {

crates/oxide/src/extractor/pre_processors/ruby.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ impl PreProcessor for Ruby {
9696

9797
cursor.advance();
9898
continue;
99-
},
99+
}
100100

101101
b'\'' => {
102102
cursor.advance();
@@ -116,7 +116,7 @@ impl PreProcessor for Ruby {
116116

117117
cursor.advance();
118118
continue;
119-
},
119+
}
120120

121121
// Replace comments in Ruby files
122122
b'#' => {
@@ -130,15 +130,15 @@ impl PreProcessor for Ruby {
130130

131131
// Everything else is part of the comment and replaced
132132
_ => {
133-
result[cursor.pos] = b' ';
134-
cursor.advance();
135-
},
133+
result[cursor.pos] = b' ';
134+
cursor.advance();
135+
}
136136
};
137137
}
138138

139139
cursor.advance();
140140
continue;
141-
},
141+
}
142142

143143
_ => {}
144144
}

0 commit comments

Comments
 (0)