Commit dd0c42bc authored by nanahira's avatar nanahira

skip image when data not exists

parent a844d1bb
Pipeline #26025 failed with stages
in 21 seconds
......@@ -55,7 +55,7 @@ namespace ImgGen
Console.WriteLine($"Card {code} not found!");
Data data = new Data
{
code = code,
code = 0,
name = "???",
text = "???"
};
......@@ -91,4 +91,3 @@ namespace ImgGen
}
}
}
......@@ -149,6 +149,9 @@ namespace ImgGen
public Bitmap GetImage(int code)
{
Data data = DataManager.GetData(code);
if (data.code == 0) {
return null;
}
return DrawCard(data);
}
......
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