mirror of
https://github.com/servo/servo.git
synced 2025-08-04 05:00:08 +01:00
Require at least one value when parsing 'content'
This commit is contained in:
parent
a97893a3ed
commit
19b390049c
1 changed files with 4 additions and 2 deletions
|
@ -698,8 +698,10 @@ pub mod longhands {
|
||||||
Ok(Token::QuotedString(value)) => {
|
Ok(Token::QuotedString(value)) => {
|
||||||
content.push(ContentItem::StringContent(value.into_owned()))
|
content.push(ContentItem::StringContent(value.into_owned()))
|
||||||
}
|
}
|
||||||
Ok(_) => return Err(()),
|
Err(()) if !content.is_empty() => {
|
||||||
Err(()) => return Ok(SpecifiedValue::Content(content))
|
return Ok(SpecifiedValue::Content(content))
|
||||||
|
}
|
||||||
|
_ => return Err(())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue