@@ -74,7 +74,7 @@ func ReplaceResourceBlock(workingDirectory, targetAddress string, newBlocks []*h
7474 f .Body ().AppendNewline ()
7575 }
7676 if found {
77- if err := os .WriteFile (filepath .Join (workingDirectory , file .Name ()), hclwrite .Format (f .Bytes ()), 0600 ); err != nil {
77+ if err := os .WriteFile (filepath .Join (workingDirectory , file .Name ()), hclwrite .Format (f .Bytes ()), 0600 ); err != nil { // #nosec G703
7878 log .Printf ("[Error] saving configuration %s: %+v" , file .Name (), err )
7979 }
8080 return nil
@@ -103,7 +103,7 @@ func ReplaceGenericOutputs(workingDirectory string, outputs []Output) error {
103103 ReplaceOutputs (block , outputs )
104104 }
105105 }
106- if err := os .WriteFile (filepath .Join (workingDirectory , file .Name ()), hclwrite .Format (f .Bytes ()), 0600 ); err != nil {
106+ if err := os .WriteFile (filepath .Join (workingDirectory , file .Name ()), hclwrite .Format (f .Bytes ()), 0600 ); err != nil { // #nosec G703
107107 log .Printf ("[Error] saving configuration %s: %+v" , file .Name (), err )
108108 }
109109 }
@@ -147,7 +147,7 @@ func UpdateMigratedResourceBlock(workingDirectory string, resources []AzapiUpdat
147147 }
148148 }
149149
150- if err := os .WriteFile (filepath .Join (workingDirectory , file .Name ()), hclwrite .Format (f .Bytes ()), 0600 ); err != nil {
150+ if err := os .WriteFile (filepath .Join (workingDirectory , file .Name ()), hclwrite .Format (f .Bytes ()), 0600 ); err != nil { // #nosec G703
151151 log .Printf ("[Error] saving configuration %s: %+v" , file .Name (), err )
152152 }
153153 }
0 commit comments