mirror of
https://github.com/thelounge/thelounge
synced 2024-11-22 03:53:08 +00:00
server: remove static props which are currently unused
This commit is contained in:
parent
9ab9ad0f56
commit
56215382a3
1 changed files with 1 additions and 1 deletions
|
@ -38,7 +38,6 @@ class Chan {
|
||||||
data?: any;
|
data?: any;
|
||||||
closed?: boolean;
|
closed?: boolean;
|
||||||
num_users?: number;
|
num_users?: number;
|
||||||
static optionalProperties = ["userAway", "special", "data", "closed", "num_users"];
|
|
||||||
|
|
||||||
constructor(attr?: Partial<Chan>) {
|
constructor(attr?: Partial<Chan>) {
|
||||||
_.defaults(this, attr, {
|
_.defaults(this, attr, {
|
||||||
|
@ -232,6 +231,7 @@ class Chan {
|
||||||
num_users: this.num_users,
|
num_users: this.num_users,
|
||||||
};
|
};
|
||||||
// TODO: funny array mutation below might need to be reproduced
|
// TODO: funny array mutation below might need to be reproduced
|
||||||
|
// static optionalProperties = ["userAway", "special", "data", "closed", "num_users"];
|
||||||
// return Object.keys(this).reduce((newChannel, prop) => {
|
// return Object.keys(this).reduce((newChannel, prop) => {
|
||||||
// if (Chan.optionalProperties.includes(prop)) {
|
// if (Chan.optionalProperties.includes(prop)) {
|
||||||
// if (this[prop] !== undefined || (Array.isArray(this[prop]) && this[prop].length)) {
|
// if (this[prop] !== undefined || (Array.isArray(this[prop]) && this[prop].length)) {
|
||||||
|
|
Loading…
Reference in a new issue