@@ -328,14 +328,14 @@ func resourceGithubTeamDelete(d *schema.ResourceData, meta any) error {
328328 ctx := context .WithValue (context .Background (), ctxId , d .Id ())
329329
330330 _ , err = client .Teams .DeleteTeamByID (ctx , orgId , id )
331- /*
332- When deleting a team and it failed, we need to check if it has already been deleted meanwhile.
333- This could be the case when deleting nested teams via Terraform by looping through a module
334- or resource and the parent team might have been deleted already. If the parent team had
335- been deleted already (via parallel runs), the child team is also already gone (deleted by
336- GitHub automatically) .
337- So we're checking if it still exists and if not, simply remove it from TF state.
338- */
331+ // When deleting a team and it failed, we need to check if it has already been deleted meanwhile.
332+ // This could be the case when deleting nested teams via Terraform by looping through a module
333+ // or resource and the parent team might have been deleted already. If the parent team had
334+ // been deleted already (via parallel runs), the child team is also already gone (deleted by
335+ // GitHub automatically).
336+ // So we're checking if it still exists and if not, simply remove it from TF state .
337+ //
338+ // https://docs.github.com/en/enterprise-cloud@latest/rest/teams/teams?apiVersion=2022-11-28#delete-a-team
339339 if err != nil {
340340 // Fetch the team in order to see if it exists or not (http 404)
341341 _ , _ , err = client .Teams .GetTeamByID (ctx , orgId , id )
0 commit comments