daydream

A small matrix web client written in rust
git clone git://archive.git.mtrnord.blog/daydream-mx/daydream.git
Log | Files | Refs | README | LICENSE

commit e1dc5cc0e8e7fe7f92b66d206cc6645e630f8ce3
parent fe90117ef431bcb9dc04bfee6de997b538940b35
Author: Marcel <mtrnord1@gmail.com>
Date:   Sat, 13 Jun 2020 15:38:11 +0200

Remove unused variables

Took 2 minutes

Diffstat:
A.idea/jsonSchemas.xml | 26++++++++++++++++++++++++++
M.travis.yml | 2+-
Msrc/app/components/event_list.rs | 17-----------------
3 files changed, 27 insertions(+), 18 deletions(-)

diff --git a/.idea/jsonSchemas.xml b/.idea/jsonSchemas.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project version="4"> + <component name="JsonSchemaMappingsProjectConfiguration"> + <state> + <map> + <entry key="travis"> + <value> + <SchemaInfo> + <option name="name" value="travis" /> + <option name="relativePathToSchema" value="https://json.schemastore.org/travis" /> + <option name="applicationDefined" value="true" /> + <option name="patterns"> + <list> + <Item> + <option name="path" value=".travis.yml" /> + </Item> + </list> + </option> + </SchemaInfo> + </value> + </entry> + </map> + </state> + </component> +</project> +\ No newline at end of file diff --git a/.travis.yml b/.travis.yml @@ -3,7 +3,7 @@ language: rust INSTALL_NODE_VIA_NVM: &INSTALL_NODE_VIA_NVM | rustup target add wasm32-unknown-unknown - curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.35.3/install.sh | bash + curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | bash source ~/.nvm/nvm.sh nvm install 14.4.0 diff --git a/src/app/components/event_list.rs b/src/app/components/event_list.rs @@ -195,23 +195,6 @@ impl EventList { fn get_event(&self, prev_event: Option<MessageEvent>, event: &MessageEvent) -> Html { // TODO make encryption supported - let new_user = if prev_event.is_some() { - prev_event.clone().unwrap().sender != event.sender - } else { - true - }; - - let sender_displayname = { - let room = self.props.current_room.as_ref().unwrap(); - match room.members.get(&event.sender) { - None => event.sender.to_string(), - Some(member) => member - .display_name - .as_ref() - .map(ToString::to_string) - .unwrap_or_else(|| event.sender.to_string()), - } - }; match &event.content { MessageEventContent::Text(text_event) => { html! {