mirror of
https://github.com/m1k1o/neko.git
synced 2025-08-02 16:29:55 +02:00
add legacy webrtc handler.
This commit is contained in:
parent
1d8ec58fbc
commit
9ea9c1c208
4 changed files with 161 additions and 0 deletions
|
@ -68,6 +68,12 @@ func (session *SessionCtx) IsHost() bool {
|
|||
return session.manager.isHost(session)
|
||||
}
|
||||
|
||||
// only needed for legacy webrtc handler
|
||||
func (session *SessionCtx) LegacyIsHost() bool {
|
||||
implicitHosting := session.manager.Settings().ImplicitHosting
|
||||
return !(!implicitHosting && !session.manager.isHost(session)) || (implicitHosting && !session.profile.CanHost)
|
||||
}
|
||||
|
||||
func (session *SessionCtx) SetAsHost() {
|
||||
session.manager.setHost(session, session)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue