mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 12:24:38 +03:00
Model refactor (#3915)
* Add mockery config file * Move basic file/folder structs to models * Fix hack due to import loop * Move file interfaces to models * Move folder interfaces to models * Move scene interfaces to models * Move scene marker interfaces to models * Move image interfaces to models * Move gallery interfaces to models * Move gallery chapter interfaces to models * Move studio interfaces to models * Move movie interfaces to models * Move performer interfaces to models * Move tag interfaces to models * Move autotag interfaces to models * Regenerate mocks
This commit is contained in:
@@ -20,7 +20,7 @@ type Cache struct {
|
||||
// against. This means that performers with single-letter words in their names could potentially
|
||||
// be missed.
|
||||
// This query is expensive, so it's queried once and cached, if the cache if provided.
|
||||
func getSingleLetterPerformers(ctx context.Context, c *Cache, reader PerformerAutoTagQueryer) ([]*models.Performer, error) {
|
||||
func getSingleLetterPerformers(ctx context.Context, c *Cache, reader models.PerformerAutoTagQueryer) ([]*models.Performer, error) {
|
||||
if c == nil {
|
||||
c = &Cache{}
|
||||
}
|
||||
@@ -53,7 +53,7 @@ func getSingleLetterPerformers(ctx context.Context, c *Cache, reader PerformerAu
|
||||
|
||||
// getSingleLetterStudios returns all studios with names that start with single character words.
|
||||
// See getSingleLetterPerformers for details.
|
||||
func getSingleLetterStudios(ctx context.Context, c *Cache, reader StudioAutoTagQueryer) ([]*models.Studio, error) {
|
||||
func getSingleLetterStudios(ctx context.Context, c *Cache, reader models.StudioAutoTagQueryer) ([]*models.Studio, error) {
|
||||
if c == nil {
|
||||
c = &Cache{}
|
||||
}
|
||||
@@ -86,7 +86,7 @@ func getSingleLetterStudios(ctx context.Context, c *Cache, reader StudioAutoTagQ
|
||||
|
||||
// getSingleLetterTags returns all tags with names that start with single character words.
|
||||
// See getSingleLetterPerformers for details.
|
||||
func getSingleLetterTags(ctx context.Context, c *Cache, reader TagAutoTagQueryer) ([]*models.Tag, error) {
|
||||
func getSingleLetterTags(ctx context.Context, c *Cache, reader models.TagAutoTagQueryer) ([]*models.Tag, error) {
|
||||
if c == nil {
|
||||
c = &Cache{}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user