mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 04:14:39 +03:00
Limit duplicate matching to files that have ~ same duration (#3663)
* Limit duplicate matching to files that have ~ same duration * Add UI for duration diff --------- Co-authored-by: WithoutPants <53250216+WithoutPants@users.noreply.github.com>
This commit is contained in:
@@ -4237,7 +4237,8 @@ func TestSceneStore_FindDuplicates(t *testing.T) {
|
||||
|
||||
withRollbackTxn(func(ctx context.Context) error {
|
||||
distance := 0
|
||||
got, err := qb.FindDuplicates(ctx, distance)
|
||||
durationDiff := -1.
|
||||
got, err := qb.FindDuplicates(ctx, distance, durationDiff)
|
||||
if err != nil {
|
||||
t.Errorf("SceneStore.FindDuplicates() error = %v", err)
|
||||
return nil
|
||||
@@ -4246,7 +4247,8 @@ func TestSceneStore_FindDuplicates(t *testing.T) {
|
||||
assert.Len(t, got, dupeScenePhashes)
|
||||
|
||||
distance = 1
|
||||
got, err = qb.FindDuplicates(ctx, distance)
|
||||
durationDiff = -1.
|
||||
got, err = qb.FindDuplicates(ctx, distance, durationDiff)
|
||||
if err != nil {
|
||||
t.Errorf("SceneStore.FindDuplicates() error = %v", err)
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user