Skip to content
Snippets Groups Projects
Unverified Commit 13f38171 authored by syuilo's avatar syuilo
Browse files

Validate param

parent 70897c0e
No related branches found
No related tags found
No related merge requests found
......@@ -15,6 +15,8 @@ export default class extends Channel {
const q: Array<string[]> = params.q;
if (q == null) return;
// Subscribe stream
this.subscriber.on('hashtag', async note => {
const matched = q.some(tags => tags.every(tag => note.tags.map((t: string) => t.toLowerCase()).includes(tag.toLowerCase())));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment