Commit 13526524 authored by twanvl's avatar twanvl

formating; explicitly return nil from text_to_color on failure. The latter is...

formating; explicitly return nil from text_to_color on failure. The latter is needed because a warning will be added to 2.0.1 about missing returns (not yet in trunk)
parent 7eca7be1
......@@ -135,7 +135,7 @@ text_to_color := {
else mana_to_color(hybrid: "")
)
)
)
) else nil
}
# The color of a card
......@@ -148,7 +148,7 @@ is_spell := match@(match: "(?i)Instant|Sorcery")
card_color := {
# usually the color of mana
text_color := text_to_color(rules_text, land: is_land(type));
if text_color == "" then (
if text_color == nil then (
mana_color := mana_to_color(colors: color_filter(casting_cost), hybrid: color_filterH(casting_cost))
if mana_color == "colorless" and is_land (type) then land_to_color(watermark)
else if mana_color == "colorless" and is_artifact(type) then "artifact"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment