code: def _get_msupdate_status():
      '''
      Check to see if Microsoft Update is Enabled
      Return Boolean
      '''
      # To get the status of Microsoft Update we actually have to check the
      # Microsoft Update Service Manager
      # Initialize the PyCom system
      with salt.utils.winapi.Com():
          # Create a ServiceManager Object
          obj_sm = win32com.client.Dispatch('Microsoft.Update.ServiceManager')
  
      # Return a collection of loaded Services
      col_services = obj_sm.Services
  
      # Loop through the collection to find the Microsoft Udpate Service
      # If it exists return True otherwise False
      for service in col_services:
          if service.name == 'Microsoft Update':
              return True
  
      return Falsf _get_msupdate_status():
      '''
      Check to see if Microsoft Update is Enabled
      Return Boolean
      '''
      # To get the status of Microsoft Update we actually have to check the
      # Microsoft Update Service Manager
      # Initialize the PyCom system
      with salt.utils.winapi.Com():
          # Create a ServiceManager Object
          obj_sm = win32com.client.Dispatch('Microsoft.Update.ServiceManager')
  
      # Return a collection of loaded Services
      col_services = obj_sm.Services
  
      # Loop through the collection to find the Microsoft Udpate Service
      # If it exists return True otherwise False
      for service in col_services:
          if service.name == 'Microsoft Update':
              return True
  
      return False
docs: Check to see if Microsoft Update is Enabled
      Return Boolean