mirror of
https://github.com/stashapp/stash.git
synced 2025-12-18 04:44:37 +03:00
Autotag scraper (#1817)
* Refactor scraper structures * Move matching code into new package * Add autotag scraper * Always check first letter of auto-tag names * Account for nulls Co-authored-by: Kermie <kermie@isinthe.house>
This commit is contained in:
@@ -12,8 +12,8 @@ import (
|
||||
"github.com/Yamashou/gqlgenc/client"
|
||||
|
||||
"github.com/stashapp/stash/pkg/logger"
|
||||
"github.com/stashapp/stash/pkg/match"
|
||||
"github.com/stashapp/stash/pkg/models"
|
||||
"github.com/stashapp/stash/pkg/scraper"
|
||||
"github.com/stashapp/stash/pkg/scraper/stashbox/graphql"
|
||||
"github.com/stashapp/stash/pkg/utils"
|
||||
)
|
||||
@@ -644,7 +644,7 @@ func sceneFragmentToScrapedScene(txnManager models.TransactionManager, s *graphq
|
||||
RemoteSiteID: &studioID,
|
||||
}
|
||||
|
||||
err := scraper.MatchScrapedStudio(r.Studio(), ss.Studio)
|
||||
err := match.ScrapedStudio(r.Studio(), ss.Studio)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -653,7 +653,7 @@ func sceneFragmentToScrapedScene(txnManager models.TransactionManager, s *graphq
|
||||
for _, p := range s.Performers {
|
||||
sp := performerFragmentToScrapedScenePerformer(p.Performer)
|
||||
|
||||
err := scraper.MatchScrapedPerformer(pqb, sp)
|
||||
err := match.ScrapedPerformer(pqb, sp)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -666,7 +666,7 @@ func sceneFragmentToScrapedScene(txnManager models.TransactionManager, s *graphq
|
||||
Name: t.Name,
|
||||
}
|
||||
|
||||
err := scraper.MatchScrapedTag(tqb, st)
|
||||
err := match.ScrapedTag(tqb, st)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user