html terminal
Diffstat (limited to 'src/bot/schematic.rs')
-rw-r--r--src/bot/schematic.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bot/schematic.rs b/src/bot/schematic.rs
index 2499ca9..16d1b07 100644
--- a/src/bot/schematic.rs
+++ b/src/bot/schematic.rs
@@ -45,7 +45,7 @@ pub async fn draw(ctx: Context<'_>, schematic: String) -> Result<()> {
async fn send(ctx: &Context<'_>, s: &Schematic<'_>, send_schematic: bool) -> Result<()> {
let n = strip_colors(s.tags.get("name").unwrap());
- let p = unsafe { s.render() };
+ let p = s.render();
let p = RawImage::new(
p.width(),
p.height(),
@@ -53,7 +53,7 @@ async fn send(ctx: &Context<'_>, s: &Schematic<'_>, send_schematic: bool) -> Res
transparent_color: None,
},
BitDepth::Eight,
- p.into_vec(),
+ p.buffer,
)
.unwrap();
let p = p