Browse Source

cool I can simplify this now

pull/112/head
jake 2 years ago
committed by andy
parent
commit
eac0a31056
  1. 5
      src/ship/items/actions.rs

5
src/ship/items/actions.rs

@ -80,7 +80,7 @@ pub async fn pick_up_item<EG>(
where
EG: EntityGateway,
{
let result: Result<TriggerCreateItem, ItemStateError> = entity_gateway.with_transaction(|transaction| async move {
entity_gateway.with_transaction(|transaction| async move {
let item_state_proxy = ItemStateProxy::new(item_state);
let ((item_state_proxy, transaction), result) = ItemStateAction::default()
.act(take_item_from_floor(character.id, *item_id))
@ -89,8 +89,7 @@ where
.await?;
item_state_proxy.commit();
Ok((transaction, result))
}).await;
result
}).await
}
pub async fn drop_item<EG>(

Loading…
Cancel
Save