From c203d62ba40bb5285af8b323948dfee7b04fe2d0 Mon Sep 17 00:00:00 2001 From: 0xbigz <83473873+0xbigz@users.noreply.github.com> Date: Mon, 2 Dec 2024 12:37:40 -0500 Subject: [PATCH 1/2] admin.rs: update spot-decimals invariant to 4 --- programs/drift/src/instructions/admin.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/programs/drift/src/instructions/admin.rs b/programs/drift/src/instructions/admin.rs index d1feb9054..bc048241f 100644 --- a/programs/drift/src/instructions/admin.rs +++ b/programs/drift/src/instructions/admin.rs @@ -193,7 +193,7 @@ pub fn handle_initialize_spot_market( ) } else { validate!( - ctx.accounts.spot_market_mint.decimals >= 6, + ctx.accounts.spot_market_mint.decimals >= 4, ErrorCode::InvalidSpotMarketInitialization, "Mint decimals must be greater than or equal to 6" )?; From 3b0f4ad556938444bc35ad93cf64b7e65325e375 Mon Sep 17 00:00:00 2001 From: Chris Heaney Date: Mon, 2 Dec 2024 14:57:54 -0500 Subject: [PATCH 2/2] change to 5 --- programs/drift/src/instructions/admin.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/programs/drift/src/instructions/admin.rs b/programs/drift/src/instructions/admin.rs index bc048241f..dd196b1c3 100644 --- a/programs/drift/src/instructions/admin.rs +++ b/programs/drift/src/instructions/admin.rs @@ -193,9 +193,9 @@ pub fn handle_initialize_spot_market( ) } else { validate!( - ctx.accounts.spot_market_mint.decimals >= 4, + ctx.accounts.spot_market_mint.decimals >= 5, ErrorCode::InvalidSpotMarketInitialization, - "Mint decimals must be greater than or equal to 6" + "Mint decimals must be greater than or equal to 5" )?; validate!(