Skip to content

Commit e10c3cc

Browse files
fix: use diag.Errorf for slug validation error
1 parent 3ef03df commit e10c3cc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

github/data_source_github_enterprise_team.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ func dataSourceGithubEnterpriseTeamRead(ctx context.Context, d *schema.ResourceD
8484
if te == nil {
8585
teamSlug := strings.TrimSpace(d.Get("slug").(string))
8686
if teamSlug == "" {
87-
return diag.FromErr(fmt.Errorf("one of slug or team_id must be set"))
87+
return diag.Errorf("one of slug or team_id must be set")
8888
}
8989
found, _, err := client.Enterprise.GetTeam(ctx, enterpriseSlug, teamSlug)
9090
if err != nil {

0 commit comments

Comments
 (0)