CheckWitness check whether authorization correct If address is wallet address, check whether in the signature addressed list Else check whether address is calling contract address Param address: wallet address or contract address
(address common.Address)
| 209 | // Else check whether address is calling contract address |
| 210 | // Param address: wallet address or contract address |
| 211 | func (this *SmartContract) CheckWitness(address common.Address) bool { |
| 212 | if this.checkAccountAddress(address) || this.checkContractAddress(address) { |
| 213 | return true |
| 214 | } |
| 215 | return false |
| 216 | } |
| 217 | |
| 218 | func (this *SmartContract) checkAccountAddress(address common.Address) bool { |
| 219 | addresses, err := this.Config.Tx.GetSignatureAddresses() |
nothing calls this directly
no test coverage detected