1
0
mirror of https://git.ngram.ca/OpenJam/rc-servers synced 2026-08-23 23:08:52 +00:00

Allow promo codes to only be redeemed once

This commit is contained in:
NG (Graham)
2026-02-07 12:27:48 -05:00
parent 514db6fd02
commit 31d7dd462f
7 changed files with 98 additions and 0 deletions

View File

@@ -85,6 +85,7 @@ pub trait User<C>: ChatUser + SocialUser + LobbyUser + MultiplayerUser + Singlep
fn current_game_event_setter(&self) -> Box<dyn GameEventSetter>;
async fn apply_purchase(&self, action: &crate::persist::config::ShopAction) -> Result<PurchaseResult, polariton_server::operations::SimpleOpError>;
async fn currency_debit(&self, ty: CurrencyType, to_sub: u64) -> Result<(), polariton_server::operations::SimpleOpError>;
async fn mark_code_redeemed(&self, code: String) -> Result<bool, polariton_server::operations::SimpleOpError>;
}
#[async_trait::async_trait]