diff options
| author | Fuwn <[email protected]> | 2021-04-30 17:59:18 +0000 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2021-04-30 17:59:18 +0000 |
| commit | 5ec0a47413d8623660156dc4049f98dffee7b35b (patch) | |
| tree | b1f5d5b860ffd48ad9c36fdc8b378bb1326d855e /src/server/cmd/commands/text/parse.rs | |
| parent | feat(hub): *implement* new commands; subscribe room, subscribe distance, tele... (diff) | |
| download | whirl-5ec0a47413d8623660156dc4049f98dffee7b35b.tar.xz whirl-5ec0a47413d8623660156dc4049f98dffee7b35b.zip | |
refactor(cmds): more orphan module functions to methods within struct
The rest of the current commands will also receive this refactor... when I have time.
Diffstat (limited to 'src/server/cmd/commands/text/parse.rs')
| -rw-r--r-- | src/server/cmd/commands/text/parse.rs | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/src/server/cmd/commands/text/parse.rs b/src/server/cmd/commands/text/parse.rs deleted file mode 100644 index 6505ace..0000000 --- a/src/server/cmd/commands/text/parse.rs +++ /dev/null @@ -1,13 +0,0 @@ -// Copyleft (ɔ) 2021-2021 The Whirlsplash Collective -// SPDX-License-Identifier: GPL-3.0-only - -use std::str::from_utf8; - -use crate::server::cmd::commands::text::structure::Text; - -pub fn parse_text(data: Vec<u8>, username: &str) -> Text { - Text { - sender: username.to_string(), - content: from_utf8(&data[6..]).unwrap().to_string(), - } -} |