Merge pull request #1189 from CosmWasm/move_method

Cleanup generated Go file
This commit is contained in:
Alexander Peters
2023-01-30 10:22:33 +01:00
committed by GitHub
2 changed files with 11 additions and 11 deletions

View File

@@ -396,3 +396,14 @@ func isSubset(super, sub []string) bool {
}
return matches == len(sub)
}
// AllAuthorizedAddresses returns the list of authorized addresses. Can be empty.
func (a AccessConfig) AllAuthorizedAddresses() []string {
switch a.Permission {
case AccessTypeAnyOfAddresses:
return a.Addresses
case AccessTypeOnlyAddress:
return []string{a.Address}
}
return []string{}
}

View File

@@ -1569,17 +1569,6 @@ func (m *AccessConfig) Unmarshal(dAtA []byte) error {
return nil
}
// si
func (a AccessConfig) AllAuthorizedAddresses() []string {
switch a.Permission {
case AccessTypeAnyOfAddresses:
return a.Addresses
case AccessTypeOnlyAddress:
return []string{a.Address}
}
return []string{}
}
func (m *Params) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0