revbot.js 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -601,6 +601,7 @@ declare class User extends Base {
601
601
  * @returns {Date} The date when the user was created.
602
602
  */
603
603
  get createdAt(): Date;
604
+ get isOwner(): boolean;
604
605
  /**
605
606
  * Gets the creation timestamp of the user in milliseconds.
606
607
  *
@@ -2048,6 +2049,8 @@ declare class UserManager extends BaseManager<User, User$1> {
2048
2049
  declare class ClientUser extends User {
2049
2050
  /** The notes channel associated with the client user, if any. */
2050
2051
  notes: NotesChannel | null;
2052
+ owner: string | null;
2053
+ constructor(client: client, data: User$1);
2051
2054
  /**
2052
2055
  * Updates the username of the client user.
2053
2056
  *
package/dist/index.d.ts CHANGED
@@ -601,6 +601,7 @@ declare class User extends Base {
601
601
  * @returns {Date} The date when the user was created.
602
602
  */
603
603
  get createdAt(): Date;
604
+ get isOwner(): boolean;
604
605
  /**
605
606
  * Gets the creation timestamp of the user in milliseconds.
606
607
  *
@@ -2048,6 +2049,8 @@ declare class UserManager extends BaseManager<User, User$1> {
2048
2049
  declare class ClientUser extends User {
2049
2050
  /** The notes channel associated with the client user, if any. */
2050
2051
  notes: NotesChannel | null;
2052
+ owner: string | null;
2053
+ constructor(client: client, data: User$1);
2051
2054
  /**
2052
2055
  * Updates the username of the client user.
2053
2056
  *
package/dist/index.js CHANGED
@@ -715,6 +715,10 @@ var User = class extends Base {
715
715
  get createdAt() {
716
716
  return UUID.timestampOf(this.id);
717
717
  }
718
+ get isOwner() {
719
+ var _a;
720
+ return this.id === ((_a = this.client.user) == null ? void 0 : _a.owner);
721
+ }
718
722
  /**
719
723
  * Gets the creation timestamp of the user in milliseconds.
720
724
  *
@@ -3235,7 +3239,7 @@ var import_node_events = require("events");
3235
3239
  var import_axios4 = require("axios");
3236
3240
 
3237
3241
  // package.json
3238
- var version = "0.1.1";
3242
+ var version = "0.1.2";
3239
3243
 
3240
3244
  // src/rest/restUtils/rateLimitQueue.ts
3241
3245
  var import_axios3 = __toESM(require("axios"));
@@ -4132,10 +4136,14 @@ _events = new WeakMap();
4132
4136
 
4133
4137
  // src/struct/clientUser.ts
4134
4138
  var ClientUser = class extends User {
4135
- constructor() {
4136
- super(...arguments);
4139
+ constructor(client3, data) {
4140
+ var _a;
4141
+ super(client3, data);
4137
4142
  /** The notes channel associated with the client user, if any. */
4138
4143
  this.notes = null;
4144
+ this.owner = null;
4145
+ this._patch(data);
4146
+ this.owner = ((_a = data.bot) == null ? void 0 : _a.owner) || null;
4139
4147
  }
4140
4148
  /**
4141
4149
  * Updates the username of the client user.