From d888156d15fe46ffa23e622122abf63c17cd808b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jo=C3=A3o=20Magalh=C3=A3es?= <joamag@gmail.com>
Date: Sun, 13 Nov 2022 10:44:38 +0000
Subject: [PATCH] refactor: small code tune

---
 src/gb.rs | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/gb.rs b/src/gb.rs
index c800004c..01f57fd0 100644
--- a/src/gb.rs
+++ b/src/gb.rs
@@ -13,7 +13,7 @@ use crate::{
 use wasm_bindgen::prelude::*;
 
 #[cfg(feature = "wasm")]
-use crate::ppu::Palette;
+use crate::ppu::{Pixel, Palette};
 
 #[cfg(feature = "wasm")]
 use std::{
@@ -259,7 +259,7 @@ impl GameBoy {
         let palette: Palette = value
             .into_iter()
             .map(|v| self.convert_value(&v))
-            .collect::<Vec<[u8; 3]>>()
+            .collect::<Vec<Pixel>>()
             .try_into()
             .unwrap();
         self.ppu().set_palette_colors(&palette);
-- 
GitLab