var zevConfig: ZevConfig = match(zevContract.contractConfig.contractConfigDetails) {
is ZevConfig -> optionalOf(zevContract.contractConfig.contractConfigDetails.ZevConfig)
is VewaConfig -> optionalOf<ZevConfig>()
}.getOrFail();
Is giving me
NPL: Error: E0009: Method 'ZevConfig' does not exist on type '/contract/ContractConfigDetails'
var zevConfig: ZevConfig = match(zevContract.contractConfig.contractConfigDetails) {
is ZevConfig -> optionalOf(zevContract.contractConfig.contractConfigDetails)
is VewaConfig -> optionalOf<ZevConfig>()
}.getOrFail();
Works as expected, but the IDE doesn’t like it “unresolved reference getOrFail” the version in the Plugin is 2025.1.9, the code
In your second example, you’re mixing return types between the ZevConfig and VewaConfig matches. Once an optional of VewaConfig and once an optional of ContractConfigDetails. It will thus not have any getOrFail