mirror of
https://codeberg.org/icewind/ugc-scaper.git
synced 2026-06-03 18:24:10 +02:00
typo
This commit is contained in:
parent
6a88ce7a7a
commit
7f85e52c71
1 changed files with 5 additions and 5 deletions
10
src/data.rs
10
src/data.rs
|
|
@ -240,24 +240,24 @@ impl GameMode {
|
||||||
pub struct Transaction {
|
pub struct Transaction {
|
||||||
pub name: String,
|
pub name: String,
|
||||||
pub steam_id: SteamID,
|
pub steam_id: SteamID,
|
||||||
pub action: TranactionAction,
|
pub action: TransactionAction,
|
||||||
pub team: TeamRef,
|
pub team: TeamRef,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Clone)]
|
#[derive(Debug, Clone)]
|
||||||
#[cfg_attr(feature = "serde", derive(serde::Serialize))]
|
#[cfg_attr(feature = "serde", derive(serde::Serialize))]
|
||||||
pub enum TranactionAction {
|
pub enum TransactionAction {
|
||||||
Joined,
|
Joined,
|
||||||
Left,
|
Left,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl FromStr for TranactionAction {
|
impl FromStr for TransactionAction {
|
||||||
type Err = ParseError;
|
type Err = ParseError;
|
||||||
|
|
||||||
fn from_str(s: &str) -> Result<Self, Self::Err> {
|
fn from_str(s: &str) -> Result<Self, Self::Err> {
|
||||||
match s {
|
match s {
|
||||||
"Joined" => Ok(TranactionAction::Joined),
|
"Joined" => Ok(TransactionAction::Joined),
|
||||||
"Left" => Ok(TranactionAction::Left),
|
"Left" => Ok(TransactionAction::Left),
|
||||||
_ => Err(ParseError::InvalidText {
|
_ => Err(ParseError::InvalidText {
|
||||||
role: "transaction action",
|
role: "transaction action",
|
||||||
text: s.to_string(),
|
text: s.to_string(),
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue