fix: empty history items being added

This was commited on Flight JQ932 :)
This commit is contained in:
PandaDEV 2024-12-12 16:42:47 +10:00
parent bc4c5a6739
commit 46fe44071d
No known key found for this signature in database
GPG key ID: 13EFF9BAF70EE75C

View file

@ -140,6 +140,9 @@ pub fn setup<R: Runtime>(app: &AppHandle<R>) {
).await;
}
} else {
if text.is_empty() {
return;
}
let _ = db::history::add_history_item(
pool,
HistoryItem::new(ContentType::Text, text, None)