크리에이터 채널 공지사항 변경 시 푸시 발송
This commit is contained in:
@@ -19,7 +19,8 @@ class FcmService {
|
||||
container: String,
|
||||
roomId: Long? = null,
|
||||
messageId: Long? = null,
|
||||
contentId: Long? = null
|
||||
contentId: Long? = null,
|
||||
creatorId: Long? = null
|
||||
) {
|
||||
if (tokens.isNotEmpty()) {
|
||||
logger.info("os: $container")
|
||||
@@ -52,6 +53,10 @@ class FcmService {
|
||||
multicastMessage.putData("content_id", contentId.toString())
|
||||
}
|
||||
|
||||
if (creatorId != null) {
|
||||
multicastMessage.putData("channel_id", creatorId.toString())
|
||||
}
|
||||
|
||||
val response = FirebaseMessaging.getInstance().sendEachForMulticast(multicastMessage.build())
|
||||
logger.info("보내기 성공: ${response.successCount}")
|
||||
logger.info("보내기 실패: ${response.failureCount}")
|
||||
|
Reference in New Issue
Block a user