Commit 6b4b36553a
6b4b36553a6d6e49cb949e8cee1f9cd5621afe4e
parent: e82c0d1618
Unsigned
Damir Jelić <poljar@termina.org.uk> · 2021-01-03 15:22 UTC
weechat-matrix: Fix some clippy warnings
Layout: unified · split
Cargo.lock
+3 −3
| @@ -3553,7 +3553,7 @@ dependencies = [ |
| 3553 | 3553 | [[package]] |
| 3554 | 3554 | name = "weechat" |
| 3555 | 3555 | version = "0.4.0" |
| 3556 | | source = "git+https://github.com/poljar/rust-weechat#4b0eca5174900be39ee9c2897c4e14e2057c44fb" |
| 3556 | source = "git+https://github.com/poljar/rust-weechat#a5f3c46ed8ad186e9b7d640d5bb632d5342f1a7d" |
| 3557 | 3557 | dependencies = [ |
| 3558 | 3558 | "async-task", |
| 3559 | 3559 | "async-trait", |
| @@ -3570,7 +3570,7 @@ dependencies = [ |
| 3570 | 3570 | [[package]] |
| 3571 | 3571 | name = "weechat-macro" |
| 3572 | 3572 | version = "0.4.0" |
| 3573 | | source = "git+https://github.com/poljar/rust-weechat#4b0eca5174900be39ee9c2897c4e14e2057c44fb" |
| 3573 | source = "git+https://github.com/poljar/rust-weechat#a5f3c46ed8ad186e9b7d640d5bb632d5342f1a7d" |
| 3574 | 3574 | dependencies = [ |
| 3575 | 3575 | "libc", |
| 3576 | 3576 | "proc-macro2", |
| @@ -3606,7 +3606,7 @@ dependencies = [ |
| 3606 | 3606 | [[package]] |
| 3607 | 3607 | name = "weechat-sys" |
| 3608 | 3608 | version = "0.4.0" |
| 3609 | | source = "git+https://github.com/poljar/rust-weechat#4b0eca5174900be39ee9c2897c4e14e2057c44fb" |
| 3609 | source = "git+https://github.com/poljar/rust-weechat#a5f3c46ed8ad186e9b7d640d5bb632d5342f1a7d" |
| 3610 | 3610 | dependencies = [ |
| 3611 | 3611 | "bindgen", |
| 3612 | 3612 | "libc", |
src/lib.rs
+1 −1
| @@ -11,7 +11,7 @@ mod room; |
| 11 | 11 | mod server; |
| 12 | 12 | |
| 13 | 13 | use std::{ |
| 14 | | cell::{Ref, RefCell, RefMut}, |
| 14 | cell::{Ref, RefCell}, |
| 15 | 15 | collections::HashMap, |
| 16 | 16 | rc::Rc, |
| 17 | 17 | }; |
src/room/mod.rs
+4 −6
| @@ -764,13 +764,11 @@ impl MatrixRoom { |
| 764 | 764 | if let Some(PrevBatch::Forward(t)) = prev_batch.as_ref() { |
| 765 | 765 | *prev_batch = Some(PrevBatch::Backwards(t.to_owned())); |
| 766 | 766 | self.sort_messages(); |
| 767 | } else if r.chunk.is_empty() { |
| 768 | *prev_batch = None; |
| 767 | 769 | } else { |
| 768 | | if r.chunk.is_empty() { |
| 769 | | *prev_batch = None; |
| 770 | | } else { |
| 771 | | *prev_batch = r.end.map(PrevBatch::Backwards); |
| 772 | | self.sort_messages(); |
| 773 | | } |
| 770 | *prev_batch = r.end.map(PrevBatch::Backwards); |
| 771 | self.sort_messages(); |
| 774 | 772 | } |
| 775 | 773 | } |
| 776 | 774 | } |