treat some fields as optional (even if the API doc says otherwise) because some cards do not have these fields
This commit is contained in:
parent
469ae79066
commit
3310523877
@ -44,15 +44,15 @@ pub struct Card {
|
|||||||
pub name: String,
|
pub name: String,
|
||||||
pub layout: String,
|
pub layout: String,
|
||||||
pub cmc: f32,
|
pub cmc: f32,
|
||||||
pub type_line: String,
|
pub type_line: Option<String>,
|
||||||
pub oracle_text: Option<String>,
|
pub oracle_text: Option<String>,
|
||||||
pub mana_cost: String,
|
pub mana_cost: Option<String>,
|
||||||
pub power: Option<String>,
|
pub power: Option<String>,
|
||||||
pub toughness: Option<String>,
|
pub toughness: Option<String>,
|
||||||
pub loyalty: Option<String>,
|
pub loyalty: Option<String>,
|
||||||
pub life_modifier: Option<String>,
|
pub life_modifier: Option<String>,
|
||||||
pub hand_modifier: Option<String>,
|
pub hand_modifier: Option<String>,
|
||||||
pub colors: Colors,
|
pub colors: Option<Colors>,
|
||||||
pub color_indicator: Option<Colors>,
|
pub color_indicator: Option<Colors>,
|
||||||
pub color_identity: Colors,
|
pub color_identity: Colors,
|
||||||
pub all_parts: Option<Vec<RelatedCard>>,
|
pub all_parts: Option<Vec<RelatedCard>>,
|
||||||
@ -99,7 +99,7 @@ pub struct CardFace {
|
|||||||
pub type_line: String,
|
pub type_line: String,
|
||||||
pub oracle_text: Option<String>,
|
pub oracle_text: Option<String>,
|
||||||
pub mana_cost: String,
|
pub mana_cost: String,
|
||||||
pub colors: Colors,
|
pub colors: Option<Colors>,
|
||||||
pub color_indicator: Option<Colors>,
|
pub color_indicator: Option<Colors>,
|
||||||
pub power: Option<String>,
|
pub power: Option<String>,
|
||||||
pub toughness: Option<String>,
|
pub toughness: Option<String>,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user