Skip to content

Commit

Permalink
Merge pull request #24053 from sebhcp/fix-typo
Browse files Browse the repository at this point in the history
Fix typo in error output of 'mssql' resources
  • Loading branch information
tombuildsstuff authored Nov 28, 2023
2 parents 7a13044 + ac4c539 commit 8ee43b3
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ func resourceMsSqlDatabaseVulnerabilityAssessmentRuleBaselineCreateUpdate(d *plu
d.Get("baseline_name").(string))

if _, err := client.CreateOrUpdate(ctx, id.ResourceGroup, id.ServerName, id.DatabaseName, id.RuleName, sql.VulnerabilityAssessmentPolicyBaselineName(id.BaselineName), *parameters); err != nil {
return fmt.Errorf("updataing database vulnerability assessment rule baseline: %s", err)
return fmt.Errorf("updating database vulnerability assessment rule baseline: %s", err)
}

d.SetId(id.ID())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ func resourceMsSqlServerSecurityAlertPolicyCreateUpdate(d *pluginsdk.ResourceDat

future, err := client.CreateOrUpdate(ctx, resourceGroupName, serverName, *alertPolicy)
if err != nil {
return fmt.Errorf("updataing mssql server security alert policy: %v", err)
return fmt.Errorf("updating mssql server security alert policy: %v", err)
}

if err = future.WaitForCompletionRef(ctx, client.Client); err != nil {
Expand Down Expand Up @@ -241,7 +241,7 @@ func resourceMsSqlServerSecurityAlertPolicyDelete(d *pluginsdk.ResourceData, met

future, err := client.CreateOrUpdate(ctx, id.ResourceGroup, id.ServerName, disabledPolicy)
if err != nil {
return fmt.Errorf("updataing mssql server security alert policy: %v", err)
return fmt.Errorf("updating mssql server security alert policy: %v", err)
}

if err = future.WaitForCompletionRef(ctx, client.Client); err != nil {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ func resourceMsSqlServerVulnerabilityAssessmentCreateUpdate(d *pluginsdk.Resourc

result, err := client.CreateOrUpdate(ctx, id.ResourceGroup, id.ServerName, vulnerabilityAssessment)
if err != nil {
return fmt.Errorf("updataing mssql server vulnerability assessment: %v", err)
return fmt.Errorf("updating mssql server vulnerability assessment: %v", err)
}

if result.ID == nil {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ func resourceMsSqlManagedInstanceSecurityAlertPolicyCreate(d *pluginsdk.Resource

future, err := client.CreateOrUpdate(ctx, resourceGroupName, managedInstanceName, *alertPolicy)
if err != nil {
return fmt.Errorf("updataing managed instance security alert policy: %v", err)
return fmt.Errorf("updating managed instance security alert policy: %v", err)
}

if err = future.WaitForCompletionRef(ctx, client.Client); err != nil {
Expand Down Expand Up @@ -218,7 +218,7 @@ func resourceMsSqlManagedInstanceSecurityAlertPolicyUpdate(d *pluginsdk.Resource

future, err := client.CreateOrUpdate(ctx, resourceGroupName, instanceName, existing)
if err != nil {
return fmt.Errorf("updataing managed instance security alert policy: %v", err)
return fmt.Errorf("updating managed instance security alert policy: %v", err)
}

if err = future.WaitForCompletionRef(ctx, client.Client); err != nil {
Expand Down Expand Up @@ -319,7 +319,7 @@ func resourceMsSqlManagedInstanceSecurityAlertPolicyDelete(d *pluginsdk.Resource

future, err := client.CreateOrUpdate(ctx, id.ResourceGroup, id.ManagedInstanceName, disabledPolicy)
if err != nil {
return fmt.Errorf("updataing managed instance security alert policy: %v", err)
return fmt.Errorf("updating managed instance security alert policy: %v", err)
}

if err = future.WaitForCompletionRef(ctx, client.Client); err != nil {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ func resourceMsSqlManagedInstanceVulnerabilityAssessmentCreate(d *pluginsdk.Reso
}

if _, err = client.CreateOrUpdate(ctx, id.ResourceGroup, id.ManagedInstanceName, vulnerabilityAssessment); err != nil {
return fmt.Errorf("updataing %s: %v", id.ID(), err)
return fmt.Errorf("updating %s: %v", id.ID(), err)
}

d.SetId(id.ID())
Expand Down Expand Up @@ -149,7 +149,7 @@ func resourceMsSqlManagedInstanceVulnerabilityAssessmentUpdate(d *pluginsdk.Reso
}

if _, err = client.CreateOrUpdate(ctx, id.ResourceGroup, id.ManagedInstanceName, vulnerabilityAssessment); err != nil {
return fmt.Errorf("updataing %s: %v", id.ID(), err)
return fmt.Errorf("updating %s: %v", id.ID(), err)
}

d.SetId(id.ID())
Expand Down
2 changes: 1 addition & 1 deletion internal/services/mysql/mysql_server_resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@ func resourceMySqlServerUpdate(d *pluginsdk.ResourceData, meta interface{}) erro
alert := expandSecurityAlertPolicy(v)
if alert != nil {
if err = securityClient.CreateOrUpdateThenPoll(ctx, securityAlertId, *alert); err != nil {
return fmt.Errorf("updataing mysql server security alert policy: %v", err)
return fmt.Errorf("updating mysql server security alert policy: %v", err)
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion internal/services/postgres/postgresql_server_resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,7 @@ func resourcePostgreSQLServerCreate(d *pluginsdk.ResourceData, meta interface{})
alert := expandSecurityAlertPolicy(v)
if alert != nil {
if err = securityClient.CreateOrUpdateThenPoll(ctx, securityAlertId, *alert); err != nil {
return fmt.Errorf("updataing security alert policy for %s: %v", id, err)
return fmt.Errorf("updating security alert policy for %s: %v", id, err)
}
}
}
Expand Down

0 comments on commit 8ee43b3

Please sign in to comment.