mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-10-20 17:41:37 +00:00
Remove unused MessageQueue method
This commit is contained in:
parent
125c9767f1
commit
f166cc93cd
1 changed files with 0 additions and 13 deletions
|
|
@ -80,17 +80,4 @@ impl<T: Clone> MessageQueue<T> {
|
|||
pub fn cursor(&self) -> u32 {
|
||||
self.messages.read().unwrap().len() as u32
|
||||
}
|
||||
|
||||
pub fn get_messages_since(&self, cursor: u32) -> (u32, Vec<T>) {
|
||||
let messages = self.messages.read().unwrap();
|
||||
|
||||
let current_cursor = messages.len() as u32;
|
||||
|
||||
// Cursor is out of bounds or there are no new messages
|
||||
if cursor >= current_cursor {
|
||||
return (current_cursor, Vec::new());
|
||||
}
|
||||
|
||||
(current_cursor, messages[(cursor as usize)..].to_vec())
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue