mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 20:34:37 +03:00
Make title from file metadata optional
This commit is contained in:
@@ -11,7 +11,7 @@ import (
|
||||
"github.com/stashapp/stash/pkg/utils"
|
||||
)
|
||||
|
||||
func (s *singleton) Scan() {
|
||||
func (s *singleton) Scan(nameFromMetadata bool) {
|
||||
if s.Status != Idle {
|
||||
return
|
||||
}
|
||||
@@ -31,7 +31,7 @@ func (s *singleton) Scan() {
|
||||
var wg sync.WaitGroup
|
||||
for _, path := range results {
|
||||
wg.Add(1)
|
||||
task := ScanTask{FilePath: path}
|
||||
task := ScanTask{FilePath: path, NameFromMetadata: nameFromMetadata}
|
||||
go task.Start(&wg)
|
||||
wg.Wait()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user