Filter - unique lines fix for empty set

This commit is contained in:
dgtlmoon
2025-02-17 21:53:47 +01:00
parent 82211eef82
commit 9dd8ccbdee
+1 -1
View File
@@ -352,7 +352,7 @@ class model(watch_base):
# Iterate over all history texts and see if something new exists
# Always applying .strip() to start/end but optionally replace any other whitespace
def lines_contain_something_unique_compared_to_history(self, lines: list, ignore_whitespace=False):
local_lines = []
local_lines = set([])
if lines:
if ignore_whitespace:
if isinstance(lines[0], str): # Can be either str or bytes depending on what was on the disk