Skip to content

Commit

Permalink
Fix merge issues
Browse files Browse the repository at this point in the history
  • Loading branch information
BartArys committed Nov 20, 2020
1 parent 98bb1c6 commit 3bebe2f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion core/src/main/kotlin/com/gitlab/kordlib/core/entity/Embed.kt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package com.gitlab.kordlib.core.entity

import com.gitlab.kordlib.common.Color
import com.gitlab.kordlib.common.entity.EmbedType
import com.gitlab.kordlib.common.entity.optional.orEmpty
import com.gitlab.kordlib.common.entity.optional.value
import com.gitlab.kordlib.core.Kord
import com.gitlab.kordlib.core.KordObject
Expand Down Expand Up @@ -88,7 +89,7 @@ data class Embed(val data: EmbedData, override val kord: Kord) : KordObject {
/**
* The embed fields.
*/
val fields: List<Field> get() = data.fields.map { Field(it, kord) }
val fields: List<Field> get() = data.fields.orEmpty().map { Field(it, kord) }

data class Footer(val data: EmbedFooterData, override val kord: Kord) : KordObject {
val text: String get() = data.text
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import com.gitlab.kordlib.rest.service.RestClient
import io.ktor.client.*
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.channels.BroadcastChannel
import kotlinx.coroutines.flow.MutableSharedFlow
import kotlinx.coroutines.flow.toList
import kotlinx.coroutines.runBlocking
import org.junit.jupiter.api.Test
Expand All @@ -28,7 +29,7 @@ internal class CacheEntitySupplierTest {
MasterGateway(mapOf(0 to Gateway.none())),
RestClient(KtorRequestHandler("")),
Snowflake(0),
BroadcastChannel(1),
MutableSharedFlow(),
Dispatchers.Default
)

Expand Down

0 comments on commit 3bebe2f

Please sign in to comment.