From b60463eaa091d468dd490cadb9130b75f80ceaa3 Mon Sep 17 00:00:00 2001 From: andy Date: Sat, 31 Jul 2021 02:21:15 +0000 Subject: [PATCH] appease the clip --- src/ship/items/inventory.rs | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/ship/items/inventory.rs b/src/ship/items/inventory.rs index df15266..7369c40 100644 --- a/src/ship/items/inventory.rs +++ b/src/ship/items/inventory.rs @@ -240,40 +240,40 @@ impl InventoryItem { if a.is_rare_item() { return Ok(10u32) } - return Ok((ArmorShopItem::from(a).price() / 8) as u32) + Ok((ArmorShopItem::from(a).price() / 8) as u32) }, ItemDetail::Shield(s) => { if s.is_rare_item() { return Ok(10u32) } - return Ok((ArmorShopItem::from(s).price() / 8) as u32) + Ok((ArmorShopItem::from(s).price() / 8) as u32) }, ItemDetail::Unit(u) => { if u.is_rare_item() { return Ok(10u32) } - return Ok((ArmorShopItem::from(u).price() / 8) as u32) + Ok((ArmorShopItem::from(u).price() / 8) as u32) }, ItemDetail::Tool(t) => { if !matches!(t.tool, ToolType::PhotonDrop | ToolType::PhotonSphere | ToolType::PhotonCrystal) && t.is_rare_item() { return Ok(10u32) } - return Ok((ToolShopItem::from(t).price() / 8) as u32) + Ok((ToolShopItem::from(t).price() / 8) as u32) }, ItemDetail::TechniqueDisk(d) => { - return Ok((ToolShopItem::from(d).price() / 8) as u32) + Ok((ToolShopItem::from(d).price() / 8) as u32) }, ItemDetail::Mag(_m) => { - return Err(ItemManagerError::ItemNotSellable(self.clone())) + Err(ItemManagerError::ItemNotSellable(self.clone())) }, ItemDetail::ESWeapon(_e) => { - return Ok(10u32) + Ok(10u32) }, } }, // the number of stacked items sold is handled by the caller. this is just the price of 1 InventoryItem::Stacked(stacked_item) => { - return Ok((ToolShopItem::from(&stacked_item.tool).price() / 8) as u32) + Ok((ToolShopItem::from(&stacked_item.tool).price() / 8) as u32) }, } }