diff options
| author | Fuwn <[email protected]> | 2021-06-02 20:47:21 -0700 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2021-06-02 20:47:21 -0700 |
| commit | b21bcf823d990964d0d4b4c3a1ea6e2567280214 (patch) | |
| tree | a9fd4c07a84b874368721706881e67b55d5effb6 /crates/whirl_server/src/cmd/commands/property | |
| parent | refactor(server): replace more matches with enums (diff) | |
| download | whirl-b21bcf823d990964d0d4b4c3a1ea6e2567280214.tar.xz whirl-b21bcf823d990964d0d4b4c3a1ea6e2567280214.zip | |
refactor(server): final refactoring of replacing command type constants with enum values
Diffstat (limited to 'crates/whirl_server/src/cmd/commands/property')
| -rw-r--r-- | crates/whirl_server/src/cmd/commands/property/create.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/crates/whirl_server/src/cmd/commands/property/create.rs b/crates/whirl_server/src/cmd/commands/property/create.rs index 94cf75b..d689857 100644 --- a/crates/whirl_server/src/cmd/commands/property/create.rs +++ b/crates/whirl_server/src/cmd/commands/property/create.rs @@ -6,7 +6,7 @@ use whirl_config::Config; use crate::{ - cmd::constants::{PROPUPD, SESSINIT}, + cmd::constants::Command, net::{ constants::{ VAR_APPNAME, @@ -29,7 +29,7 @@ use crate::{ pub fn property_update_as_distributor() -> Vec<u8> { property_list_to_bytes( - PROPUPD, + Command::PropUpd as i32, 0xFF, vec![ NetworkProperty { @@ -66,7 +66,7 @@ pub fn property_update_as_distributor() -> Vec<u8> { pub fn property_update_as_hub() -> Vec<u8> { property_list_to_bytes( - PROPUPD, + Command::PropUpd as i32, 0xFF, vec![ NetworkProperty { @@ -107,7 +107,7 @@ pub fn property_update_as_hub() -> Vec<u8> { pub fn property_request_as_distributor() -> Vec<u8> { property_list_to_bytes( - SESSINIT as i32, + Command::SessInit as i32, 0x01, vec![ NetworkProperty { @@ -144,7 +144,7 @@ pub fn property_request_as_distributor() -> Vec<u8> { pub fn property_request_as_hub() -> Vec<u8> { property_list_to_bytes( - SESSINIT as i32, + Command::SessInit as i32, 0x01, vec![ NetworkProperty { |