mirror of
https://github.com/projectdysnomia/dysnomia.git
synced 2026-12-02 13:48:31 +02:00
This commit switches Dysnomia over to ESLint flat config for futureproofing and better maintainability. For the most part, the codebase will pass the test suite, apart from a few exceptions introduced by the stylistic plugin which I believe are reasonable to include. Additionally, JSDoc linting was added to maintain proper alignment of various features.
27 lines
721 B
JavaScript
27 lines
721 B
JavaScript
"use strict";
|
|
|
|
const ThreadChannel = require("./ThreadChannel");
|
|
|
|
/**
|
|
* Represents a public thread channel. See ThreadChannel for extra properties.
|
|
* @extends ThreadChannel
|
|
*/
|
|
class PublicThreadChannel extends ThreadChannel {
|
|
constructor(data, client, messageLimit) {
|
|
super(data, client, messageLimit);
|
|
}
|
|
|
|
update(data, client) {
|
|
super.update(data, client);
|
|
if(data.applied_tags !== undefined) {
|
|
/**
|
|
* An array of applied tag IDs for the thread (available only in threads in thread-only channels)
|
|
* @type {Array<String>?}
|
|
*/
|
|
this.appliedTags = data.applied_tags;
|
|
}
|
|
}
|
|
}
|
|
|
|
module.exports = PublicThreadChannel;
|