mirror of
https://github.com/servo/servo.git
synced 2025-08-08 06:55:31 +01:00
Use match instead of 'if let'.
This commit is contained in:
parent
c53a8e8446
commit
8061103594
1 changed files with 3 additions and 4 deletions
|
@ -2209,10 +2209,9 @@ pub extern "C" fn Servo_StyleSet_FillKeyframesForName(raw_data: RawServoStyleSet
|
||||||
|
|
||||||
for step in &animation.steps {
|
for step in &animation.steps {
|
||||||
// Override timing_function if the keyframe has animation-timing-function.
|
// Override timing_function if the keyframe has animation-timing-function.
|
||||||
let timing_function = if let Some(val) = step.get_animation_timing_function(&guard) {
|
let timing_function = match step.get_animation_timing_function(&guard) {
|
||||||
val.into()
|
Some(val) => val.into(),
|
||||||
} else {
|
None => *timing_function,
|
||||||
*timing_function
|
|
||||||
};
|
};
|
||||||
|
|
||||||
let keyframe = unsafe {
|
let keyframe = unsafe {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue