title: unable to execute terraform apply in azure devops
body: <p>I am trying to execute terraform scripts through azure devops. I am not able to apply and validate through different tasks, though terraform plan is successful terraform apply is failing with</p>
  <blockquote>
  <p>##[error]TypeError: Cannot read property 'includes' of null</p>
  </blockquote>
  <p>Here is the terraform tasks which I am using. I have tried with two different tasks</p>
  <p>1.</p>
  <pre><code>- task: ms-devlabs.custom-terraform-tasks.custom-terraform-release-task.TerraformTaskV2@2
    displayName: 'Terraform : apply -auto-approve'
    inputs:
      command: apply
      workingDirectory: '$(System.DefaultWorkingDirectory)/Terraform'
      commandOptions: '-auto-approve'
      environmentServiceNameAzureRM: 'ps-vs-sc'
      backendAzureRmResourceGroupName: '$(rgname)'
      backendAzureRmStorageAccountName: $(strname)
      backendAzureRmContainerName: $(tfContainer)
      backendAzureRmKey: '$(storagekey)'
  </code></pre>
  <ol start="2">
  <li></li>
  </ol>
  <pre><code>- task: TerraformTaskV2@2
    inputs:
      provider: 'azurerm'
      command: 'apply'
      workingDirectory: '$(System.DefaultWorkingDirectory)/Terraform'
      commandOptions: '--auto-approve'
      environmentServiceNameAzureRM: 'ps-vs1-sc'
  </code></pre>
  <p>Here is my terraform file</p>
  <pre><code>provider &quot;azurerm&quot; {
  features {}
  }
  
  terraform {
    required_providers {
      azurerm = {
        source = &quot;hashicorp/azurerm&quot;
        version = &quot;2.74.0&quot;
      }
    }
  }
  
  data &quot;azurerm_api_management&quot; &quot;example&quot; {
    name                = var.apimName
    resource_group_name = var.rgName
  }
  
  resource &quot;azurerm_api_management_api&quot; &quot;example&quot; {
    name                = var.apName
    resource_group_name = var.rgName
    api_management_name = var.apimname
    revision            = &quot;1&quot;
    display_name        = &quot;Example API1&quot;
    path                = &quot;example1&quot;
    protocols           = [&quot;https&quot;]
    service_url         = &quot;http://123.0.0.0:8000&quot;
    subscription_required  = true
  
    import {
      content_format = &quot;openapi+json&quot;
      content_value  = #{storageaccountlink}#
       
  }
  </code></pre>