code: func (p *chaincodeInfoProviderImpl) GetDeployedChaincodeInfo(chainid string,
  	chaincodeDefinition *cceventmgmt.ChaincodeDefinition) (*ledger.DeployedChaincodeInfo, error) {
  	lock.Lock()
  	ledger := openedLedgers[chainid]
  	lock.Unlock()
  	if ledger == nil {
  		return nil, errors.Errorf("Ledger not opened [%s]", chainid)
  	}
  	qe, err := ledger.NewQueryExecutor()
  	if err != nil {
  		return nil, err
  	}
  	defer qe.Done()
  	deployedChaincodeInfo, err := p.deployedCCInfoProvider.ChaincodeInfo(chaincodeDefinition.Name, qe)
  	if err != nil || deployedChaincodeInfo == nil {
  		return nil, err
  	}
  	if deployedChaincodeInfo.Version != chaincodeDefinition.Version ||
  		!bytes.Equal(deployedChaincodeInfo.Hash, chaincodeDefinition.Hash) {
  		// if the deployed chaincode with the given name has different version or different hash, return nil
  		return nil, nil
  	}
  	return deployedChaincodeInfo, nil
  }
docs: // GetDeployedChaincodeInfo implements function in the interface cceventmgmt.ChaincodeInfoProvider