fix: Option removed from ValidateAuthTokenRespMsg and respective handlers, default eject reason added
This commit is contained in:
parent
c4b05e83e8
commit
105e1d0166
@ -78,7 +78,7 @@ trait ValidateAuthTokenReqMsgHdlr extends HandlerHelpers {
|
||||
state: MeetingState2x
|
||||
): MeetingState2x = {
|
||||
val event = MsgBuilder.buildValidateAuthTokenRespMsg(meetingId, userId, authToken, valid, waitForApproval, 0,
|
||||
0, Option.apply(reasonCode), Option.apply(reason))
|
||||
0, reasonCode, reason)
|
||||
outGW.send(event)
|
||||
|
||||
// send a system message to force disconnection
|
||||
@ -90,7 +90,7 @@ trait ValidateAuthTokenReqMsgHdlr extends HandlerHelpers {
|
||||
|
||||
def sendValidateAuthTokenRespMsg(meetingId: String, userId: String, authToken: String,
|
||||
valid: Boolean, waitForApproval: Boolean, registeredOn: Long, authTokenValidatedOn: Long,
|
||||
reasonCode: Option[String] = None, reason: Option[String] = None): Unit = {
|
||||
reasonCode: String = EjectReasonCode.NOT_EJECT, reason: String = "User not ejected"): Unit = {
|
||||
val event = MsgBuilder.buildValidateAuthTokenRespMsg(meetingId, userId, authToken, valid, waitForApproval, registeredOn,
|
||||
authTokenValidatedOn, reasonCode, reason)
|
||||
outGW.send(event)
|
||||
|
@ -300,6 +300,7 @@ object SystemUser {
|
||||
}
|
||||
|
||||
object EjectReasonCode {
|
||||
val NOT_EJECT = "not_eject_reason"
|
||||
val DUPLICATE_USER = "duplicate_user_in_meeting_eject_reason"
|
||||
val PERMISSION_FAILED = "not_enough_permission_eject_reason"
|
||||
val EJECT_USER = "user_requested_eject_reason"
|
||||
|
@ -86,7 +86,7 @@ object MsgBuilder {
|
||||
|
||||
def buildValidateAuthTokenRespMsg(meetingId: String, userId: String, authToken: String,
|
||||
valid: Boolean, waitForApproval: Boolean, registeredOn: Long, authTokenValidatedOn: Long,
|
||||
reasonCode: Option[String], reason: Option[String]): BbbCommonEnvCoreMsg = {
|
||||
reasonCode: String, reason: String): BbbCommonEnvCoreMsg = {
|
||||
val routing = Routing.addMsgToClientRouting(MessageTypes.DIRECT, meetingId, userId)
|
||||
val envelope = BbbCoreEnvelope(ValidateAuthTokenRespMsg.NAME, routing)
|
||||
val header = BbbClientMsgHeader(ValidateAuthTokenRespMsg.NAME, meetingId, userId)
|
||||
|
@ -6,7 +6,7 @@ import org.bigbluebutton.core.running.OutMsgRouter
|
||||
object ValidateAuthTokenRespMsgSender {
|
||||
|
||||
def send(outGW: OutMsgRouter, meetingId: String, userId: String, authToken: String,
|
||||
valid: Boolean, waitForApproval: Boolean, registeredOn: Long, authTokenValidatedOn: Long, reasonCode: Option[String], reason: Option[String]): Unit = {
|
||||
valid: Boolean, waitForApproval: Boolean, registeredOn: Long, authTokenValidatedOn: Long, reasonCode: String, reason: String): Unit = {
|
||||
val routing = Routing.addMsgToClientRouting(MessageTypes.DIRECT, meetingId, userId)
|
||||
val envelope = BbbCoreEnvelope(ValidateAuthTokenRespMsg.NAME, routing)
|
||||
val header = BbbClientMsgHeader(ValidateAuthTokenRespMsg.NAME, meetingId, userId)
|
||||
|
Loading…
Reference in New Issue
Block a user