(
connection_state: state::Connection,
message: message::protocol::Inbound,
)
| 5 | use types::DispatchFuture; |
| 6 | |
| 7 | pub fn dispatch( |
| 8 | connection_state: state::Connection, |
| 9 | message: message::protocol::Inbound, |
| 10 | ) -> DispatchFuture { |
| 11 | use error::protocol::Error; |
| 12 | use error::protocol::InboundMessageError::Unexpected; |
| 13 | use message::protocol::Inbound; |
| 14 | |
| 15 | match message { |
| 16 | Inbound::GitCommand(git_command) => git_command::dispatch(connection_state, git_command), |
| 17 | _ => Box::new(future::err(( |
| 18 | Error::InboundMessage(Unexpected), |
| 19 | connection_state, |
| 20 | ))), |
| 21 | } |
| 22 | } |
no test coverage detected