mirror of
https://github.com/YGGverse/ggemtext.git
synced 2026-03-31 17:15:33 +00:00
add empty value validation
This commit is contained in:
parent
321c428765
commit
9373faabb8
1 changed files with 3 additions and 1 deletions
|
|
@ -76,7 +76,9 @@ impl Link {
|
||||||
|
|
||||||
// Alt
|
// Alt
|
||||||
if let Some(value) = regex.get(3) {
|
if let Some(value) = regex.get(3) {
|
||||||
|
if !value.is_empty() {
|
||||||
alt = Some(GString::from(value.as_str()))
|
alt = Some(GString::from(value.as_str()))
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Some(Self {
|
Some(Self {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue