mirror of
https://github.com/stoatchat/stoatchat.git
synced 2026-07-14 13:36:59 +00:00
Add util, fix fetch DMs, fully implement delete.
This commit is contained in:
6
src/util/mod.rs
Normal file
6
src/util/mod.rs
Normal file
@@ -0,0 +1,6 @@
|
||||
use hashbrown::HashSet;
|
||||
use std::iter::FromIterator;
|
||||
|
||||
pub fn vec_to_set<T: Clone + Eq + std::hash::Hash>(data: &Vec<T>) -> HashSet<T> {
|
||||
HashSet::from_iter(data.iter().cloned())
|
||||
}
|
||||
Reference in New Issue
Block a user