mirror of https://github.com/usbharu/Hideout.git
style: スタイルを修正
This commit is contained in:
parent
dfa3bb74fb
commit
a99f7036fa
|
@ -1,3 +1,3 @@
|
||||||
package dev.usbharu.hideout.domain.model.hideout.dto
|
package dev.usbharu.hideout.domain.model.hideout.dto
|
||||||
|
|
||||||
data class PostCreateDto(val text:String,val username:String)
|
data class PostCreateDto(val text: String, val username: String)
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
package dev.usbharu.hideout.domain.model.hideout.entity
|
package dev.usbharu.hideout.domain.model.hideout.entity
|
||||||
|
|
||||||
data class Post(
|
data class Post(
|
||||||
val id:Long,
|
val id: Long,
|
||||||
val userId: Long,
|
val userId: Long,
|
||||||
val overview:String? = null,
|
val overview: String? = null,
|
||||||
val text:String,
|
val text: String,
|
||||||
val createdAt:Long,
|
val createdAt: Long,
|
||||||
val visibility: Visibility,
|
val visibility: Visibility,
|
||||||
val url:String,
|
val url: String,
|
||||||
val repostId:Long? = null,
|
val repostId: Long? = null,
|
||||||
val replyId:Long? = null
|
val replyId: Long? = null
|
||||||
)
|
)
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
package dev.usbharu.hideout.domain.model.hideout.form
|
package dev.usbharu.hideout.domain.model.hideout.form
|
||||||
|
|
||||||
data class Post(val text:String)
|
data class Post(val text: String)
|
||||||
|
|
|
@ -25,7 +25,6 @@ class PostRepositoryImpl(database: Database, private val idGenerateService: IdGe
|
||||||
suspend fun <T> query(block: suspend () -> T): T =
|
suspend fun <T> query(block: suspend () -> T): T =
|
||||||
newSuspendedTransaction(Dispatchers.IO) { block() }
|
newSuspendedTransaction(Dispatchers.IO) { block() }
|
||||||
|
|
||||||
|
|
||||||
override suspend fun save(post: Post): Post {
|
override suspend fun save(post: Post): Post {
|
||||||
return query {
|
return query {
|
||||||
Posts.insert {
|
Posts.insert {
|
||||||
|
|
Loading…
Reference in New Issue