mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-08 12:37:05 +03:00
Fix segments being deleted
This commit is contained in:
@@ -250,7 +250,7 @@ const Config: SBObject = {
|
|||||||
function encodeStoredItem<T>(data: T): T | UnencodedSegmentTimes {
|
function encodeStoredItem<T>(data: T): T | UnencodedSegmentTimes {
|
||||||
// if data is SBMap convert to json for storing
|
// if data is SBMap convert to json for storing
|
||||||
if(!(data instanceof SBMap)) return data;
|
if(!(data instanceof SBMap)) return data;
|
||||||
return Array.from(data.entries()).filter((element) => element[1] === []); // Remove empty entries
|
return Array.from(data.entries()).filter((element) => element[1].length > 0); // Remove empty entries
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user