mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-13 06:57:09 +03:00
Don't force-sync unsubmitted segments when clear confirm prompt is cancelled
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
import * as React from "react";
|
import * as React from "react";
|
||||||
|
|
||||||
import Config from "../config"
|
import Config from "../config";
|
||||||
|
|
||||||
export interface UnsubmittedVideosListItemProps {
|
export interface UnsubmittedVideosListItemProps {
|
||||||
videoID: string;
|
videoID: string;
|
||||||
@@ -54,10 +54,10 @@ class UnsubmittedVideoListItem extends React.Component<UnsubmittedVideosListItem
|
|||||||
}
|
}
|
||||||
|
|
||||||
clearSegments(): void {
|
clearSegments(): void {
|
||||||
if (confirm(chrome.i18n.getMessage("clearThis")))
|
if (confirm(chrome.i18n.getMessage("clearThis"))) {
|
||||||
delete Config.config.unsubmittedSegments[this.props.videoID]
|
delete Config.config.unsubmittedSegments[this.props.videoID]
|
||||||
|
Config.forceSyncUpdate("unsubmittedSegments")
|
||||||
Config.forceSyncUpdate("unsubmittedSegments")
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user