Skip to content

Commit

Permalink
fix: mark ClientWebSocketEvent as serializable
Browse files Browse the repository at this point in the history
  • Loading branch information
d1snin committed Sep 2, 2023
1 parent d2d1dec commit 70b1872
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
8 changes: 8 additions & 0 deletions ktor-ws-events-client/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@
* limitations under the License.
*/

plugins {
kotlin("plugin.serialization")
}

apply {
val publishingScript: String by project

Expand All @@ -38,10 +42,14 @@ kotlin {
dependencies {
val ktorVersion: String by project

val kotlinxSerializationVersion: String by project

api(project(":ktor-ws-events-commons"))

implementation("io.ktor:ktor-client-core:$ktorVersion")
implementation("io.ktor:ktor-client-websockets:$ktorVersion")

implementation("org.jetbrains.kotlinx:kotlinx-serialization-core:$kotlinxSerializationVersion")
}
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package dev.d1s.ktor.events.client

import dev.d1s.ktor.events.commons.EventReference
import kotlinx.serialization.Serializable

@Serializable
public data class ClientWebSocketEvent<T>(
val reference: EventReference,
val data: T
Expand Down

0 comments on commit 70b1872

Please sign in to comment.