Skip to content

Commit f18b8d4

Browse files
jackHay22techknowlogick
authored andcommitted
update FindSources to generic db.Find
1 parent a39fd9f commit f18b8d4

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

services/auth/source/saml/providers.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import (
1414
"time"
1515

1616
"code.gitea.io/gitea/models/auth"
17+
"code.gitea.io/gitea/models/db"
1718
"code.gitea.io/gitea/modules/httplib"
1819
"code.gitea.io/gitea/modules/svg"
1920
"code.gitea.io/gitea/modules/util"
@@ -83,7 +84,7 @@ func createProviderFromSource(source *auth.Source) (Provider, error) {
8384

8485
// GetSAMLProviders returns the list of configured SAML providers
8586
func GetSAMLProviders(ctx context.Context, isActive util.OptionalBool) ([]Provider, error) {
86-
authSources, err := auth.FindSources(ctx, auth.FindSourcesOptions{
87+
authSources, err := db.Find[auth.Source](ctx, auth.FindSourcesOptions{
8788
IsActive: isActive,
8889
LoginType: auth.SAML,
8990
})

0 commit comments

Comments
 (0)