Skip to content

Commit

Permalink
remove vip property
Browse files Browse the repository at this point in the history
  • Loading branch information
HopeBaron committed Aug 8, 2021
1 parent de33b64 commit 5dd3f38
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 10 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@

* Fixed the space in active threads get endpoint causing it to fail.
* Fixed incorrect serialization of `NUMBER` option
* Fixed Missing properties in `MemberData`, `InteractionData` and others. (#361)

## Changes

* `Region` no longer has a `vip` property

# 0.8.0-M3

Expand Down
1 change: 0 additions & 1 deletion common/src/main/kotlin/entity/DiscordGuild.kt
Original file line number Diff line number Diff line change
Expand Up @@ -419,7 +419,6 @@ data class DiscordVoiceState(
data class DiscordVoiceRegion(
val id: String,
val name: String,
val vip: Boolean,
val optimal: Boolean,
val deprecated: Boolean,
val custom: Boolean,
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/kotlin/cache/data/InteractionData.kt
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ data class InteractionData(
val member: Optional<MemberData> = Optional.Missing(),
val user: Optional<UserData> = Optional.Missing(),
val token: String,
val permissions: Optional<Permissions> = Optional.Missing(),
val permissions: Optional<Permissions>,
val version: Int,
val message: Optional<MessageData> = Optional.Missing()
) {
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/kotlin/cache/data/MemberData.kt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ data class MemberData(
val nick: Optional<String?> = Optional.Missing(),
val roles: List<Snowflake>,
val joinedAt: String,
val premiumSince: Optional<String?> = Optional.Missing(),
val premiumSince: Optional<String?>,
val pending: OptionalBoolean = OptionalBoolean.Missing
) {

Expand Down
2 changes: 1 addition & 1 deletion core/src/main/kotlin/cache/data/PartialGuildData.kt
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class PartialGuildData(
val owner: OptionalBoolean = OptionalBoolean.Missing,
val permissions: Optional<Permissions> = Optional.Missing(),
val features: List<GuildFeature>,
val welcomeScreen: Optional<WelcomeScreenData> = Optional.Missing(),
val welcomeScreen: Optional<WelcomeScreenData>,

) {
companion object {
Expand Down
3 changes: 1 addition & 2 deletions core/src/main/kotlin/cache/data/RegionData.kt
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,13 @@ data class RegionData(
val id: String,
val guildId: OptionalSnowflake,
val name: String,
val vip: Boolean,
val optimal: Boolean,
val deprecated: Boolean,
val custom: Boolean,
) {
companion object {
fun from(guildId: OptionalSnowflake, region: DiscordVoiceRegion) = with(region) {
RegionData(id, guildId, name, vip, optimal, deprecated, custom)
RegionData(id, guildId, name, optimal, deprecated, custom)
}
}
}
4 changes: 2 additions & 2 deletions core/src/main/kotlin/cache/data/RoleTagsData.kt
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import kotlinx.serialization.Serializable

@Serializable
data class RoleTagsData(
val botId: OptionalSnowflake = OptionalSnowflake.Missing,
val integrationId: OptionalSnowflake = OptionalSnowflake.Missing,
val botId: OptionalSnowflake,
val integrationId: OptionalSnowflake,
val premiumSubscriber: Boolean,
) {

Expand Down
2 changes: 0 additions & 2 deletions core/src/main/kotlin/entity/Region.kt
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ class Region(val data: RegionData, override val kord: Kord) : KordObject {

val isOptimal: Boolean get() = data.optimal

val isVip: Boolean get() = data.vip

override fun hashCode(): Int = Objects.hash(id)

override fun equals(other: Any?): Boolean = when (other) {
Expand Down

0 comments on commit 5dd3f38

Please sign in to comment.