Cleanups
This commit is contained in:
parent
11dc672e31
commit
2bfa82e3e8
@ -43,8 +43,6 @@ class OrbitClient {
|
||||
|
||||
_iterator(channel, password, options) {
|
||||
const messages = this._getMessages(channel, password, options);
|
||||
|
||||
// Iterator interface implementation
|
||||
let currentIndex = 0;
|
||||
let iterator = {
|
||||
[Symbol.iterator]() {
|
||||
@ -59,6 +57,7 @@ class OrbitClient {
|
||||
return item;
|
||||
},
|
||||
collect: () => messages
|
||||
// TODO: add first() and last() ?
|
||||
}
|
||||
|
||||
return iterator;
|
||||
|
@ -88,7 +88,7 @@ async(() => {
|
||||
|
||||
// Modes
|
||||
const password = 'hello';
|
||||
const channelModes;
|
||||
let channelModes;
|
||||
channelModes = orbit.channel(channel).setMode({ mode: "+r", params: { password: password } }); // { modes: { r: { password: 'hello' } } }
|
||||
channelModes = orbit.channel(channel, password).setMode({ mode: "+w", params: { ops: [orbit.user.id] } }); // { modes: { ... } }
|
||||
channelModes = orbit.channel(channel, password).setMode({ mode: "-r" }); // { modes: { ... } }
|
||||
|
Loading…
x
Reference in New Issue
Block a user