aboutsummaryrefslogtreecommitdiff
path: root/planetwars-server/src/modules/matches.rs
diff options
context:
space:
mode:
authorIlion Beyst <ilion.beyst@gmail.com>2022-07-06 22:41:27 +0200
committerIlion Beyst <ilion.beyst@gmail.com>2022-07-06 22:41:27 +0200
commitd7b7585dd70f9d41184cf88c2ecbd88341898c38 (patch)
tree89a7fc180152f18273159104265e7894718e8560 /planetwars-server/src/modules/matches.rs
parentb3df5c6f8cc59e099a2f1db3df8089af4abca02e (diff)
downloadplanetwars.dev-d7b7585dd70f9d41184cf88c2ecbd88341898c38.tar.xz
planetwars.dev-d7b7585dd70f9d41184cf88c2ecbd88341898c38.zip
rename code_bundle to bot_version
Diffstat (limited to 'planetwars-server/src/modules/matches.rs')
-rw-r--r--planetwars-server/src/modules/matches.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/planetwars-server/src/modules/matches.rs b/planetwars-server/src/modules/matches.rs
index 7d6a1dc..4a5a980 100644
--- a/planetwars-server/src/modules/matches.rs
+++ b/planetwars-server/src/modules/matches.rs
@@ -29,7 +29,7 @@ pub struct MatchPlayer {
}
impl MatchPlayer {
- pub fn from_code_bundle(code_bundle: &db::bots::CodeBundle) -> Self {
+ pub fn from_code_bundle(code_bundle: &db::bots::BotVersion) -> Self {
MatchPlayer {
bot_spec: code_bundle_to_botspec(code_bundle),
code_bundle_id: Some(code_bundle.id),
@@ -97,7 +97,7 @@ impl RunMatch {
}
}
-pub fn code_bundle_to_botspec(code_bundle: &db::bots::CodeBundle) -> Box<dyn BotSpec> {
+pub fn code_bundle_to_botspec(code_bundle: &db::bots::BotVersion) -> Box<dyn BotSpec> {
// TODO: get rid of this unwrap
let bundle_path = PathBuf::from(BOTS_DIR).join(code_bundle.code_bundle_path.as_ref().unwrap());