From b8dc6c28df2b88defc294991e3b955073db6f216 Mon Sep 17 00:00:00 2001 From: Edwin Date: Fri, 8 Sep 2023 16:35:34 +0800 Subject: [PATCH] Fix token convert (#1035) --- node/primitives/src/currency.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/node/primitives/src/currency.rs b/node/primitives/src/currency.rs index bcf514204..b00df4b00 100644 --- a/node/primitives/src/currency.rs +++ b/node/primitives/src/currency.rs @@ -410,6 +410,7 @@ impl CurrencyId { pub fn to_token(&self) -> Result { match self { Self::VToken(symbol) => Ok(Self::Token(*symbol)), + Self::VToken2(id) => Ok(Self::Token2(*id)), _ => Err(()), } } @@ -417,6 +418,7 @@ impl CurrencyId { pub fn to_vtoken(&self) -> Result { match self { Self::Token(symbol) => Ok(Self::VToken(*symbol)), + Self::Token2(id) => Ok(Self::VToken2(*id)), _ => Err(()), } } @@ -424,6 +426,7 @@ impl CurrencyId { pub fn to_vstoken(&self) -> Result { match self { Self::Token(symbol) => Ok(Self::VSToken(*symbol)), + Self::Token2(id) => Ok(Self::VSToken2(*id)), _ => Err(()), } }