_patch(data) {
    /**
     * The unique code of this template
     * @type {string}
     */
    this.code = data.code;

    /**
     * The name of this template
     * @type {string}
     */
    this.name = data.name;

    /**
     * The description of this template
     * @type {?string}
     */
    this.description = data.description;

    /**
     * The amount of times this template has been used
     * @type {number}
     */
    this.usageCount = data.usage_count;

    /**
     * The ID of the user that created this template
     * @type {Snowflake}
     */
    this.creatorID = data.creator_id;

    /**
     * The user that created this template
     * @type {User}
     */
    this.creator = this.client.users.add(data.creator);

    /**
     * The time of when this template was created at
     * @type {Date}
     */
    this.createdAt = new Date(data.created_at);

    /**
     * The time of when this template was last synced to the guild
     * @type {Date}
     */
    this.updatedAt = new Date(data.updated_at);

    /**
     * The ID of the guild that this template belongs to
     * @type {Snowflake}
     */
    this.guildID = data.source_guild_id;

    /**
     * The data of the guild that this template would create
     * @type {Object}
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-resource}
     */
    this.serializedGuild = data.serialized_source_guild;

    /**
     * Whether this template has unsynced changes
     * @type {?boolean}
     */
    this.unSynced = 'is_dirty' in data ? Boolean(data.is_dirty) : null;

    return this;
  }
/**
   * Builds or updates the template with the provided data.
   * @param {Object} data The raw data for the template
   * @returns {GuildTemplate}
   * @private
   */
Builds or updates the template with the provided data.
@param {Object} data The raw data for the template
@returns {GuildTemplate}
@private
Builds or updates the template with the provided data . @param { Object } data The raw data for the template @returns { GuildTemplate } @private
_patch(data) {
    this.code = data.code;
    this.name = data.name;
    this.description = data.description;
    this.usageCount = data.usage_count;
    this.creatorID = data.creator_id;
    this.creator = this.client.users.add(data.creator);
    this.createdAt = new Date(data.created_at);
    this.updatedAt = new Date(data.updated_at);
    this.guildID = data.source_guild_id;
    this.serializedGuild = data.serialized_source_guild;
    this.unSynced = 'is_dirty' in data ? Boolean(data.is_dirty) : null;
    return this;
  }
_patch ( data ) { this . code = data . code ; this . name = data . name ; this . description = data . description ; this . usageCount = data . usage_count ; this . creatorID = data . creator_id ; this . creator = this . client . users . add ( data . creator ) ; this . createdAt = new Date ( data . created_at ) ; this . updatedAt = new Date ( data . updated_at ) ; this . guildID = data . source_guild_id ; this . serializedGuild = data . serialized_source_guild ; this . unSynced = 'is_dirty' in data ? Boolean ( data . is_dirty ) : null ; return this ; }
Builds or updates the template with the provided data.
Builds or updates the template with the provided data .
/**
     * The unique code of this template
     * @type {string}
     */ /**
     * The name of this template
     * @type {string}
     */ /**
     * The description of this template
     * @type {?string}
     */ /**
     * The amount of times this template has been used
     * @type {number}
     */ /**
     * The ID of the user that created this template
     * @type {Snowflake}
     */ /**
     * The user that created this template
     * @type {User}
     */ /**
     * The time of when this template was created at
     * @type {Date}
     */ /**
     * The time of when this template was last synced to the guild
     * @type {Date}
     */ /**
     * The ID of the guild that this template belongs to
     * @type {Snowflake}
     */ /**
     * The data of the guild that this template would create
     * @type {Object}
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-resource}
     */ /**
     * Whether this template has unsynced changes
     * @type {?boolean}
     */