fix: Fixed a bug in all Servarr implementations to not try to get the current selection of a search table when an error is returned from the API

This commit is contained in:
2026-01-07 14:00:02 -07:00
parent 9cc3ccb419
commit 60c4cf1098
4 changed files with 11 additions and 2 deletions
+4
View File
@@ -272,6 +272,10 @@ impl HorizontallyScrollableText {
}
}
}
pub fn is_empty(&self) -> bool {
self.text.is_empty()
}
}
#[derive(Clone, PartialEq, Eq, Debug)]
+5
View File
@@ -176,6 +176,11 @@ mod tests {
assert_str_eq!(horizontally_scrollable_text.text, test_text);
}
#[test]
fn test_horizontally_scrollable_text_is_empty() {
assert_is_empty!(HorizontallyScrollableText::from(""))
}
#[test]
fn test_horizontally_scrollable_text_scroll_text_left() {
let horizontally_scrollable_text = HorizontallyScrollableText::from("Test string");