fix warnings
iOS CI / Build and Test SwiftUI App (push) Canceled after 0s
Build Unsigned iOS and macOS Apps / Build Unsigned iOS IPA (push) Canceled after 0s
Build Unsigned iOS and macOS Apps / Build macOS ZIP (push) Canceled after 0s

This commit is contained in:
wt committed 2026-08-10 17:18:01 +07:00
1 parent e14dc25891
commit dee1eab897
4 files changed
+288 -210

No files matched your search

+1 -1
View File
@@ -889,7 +889,7 @@ private final class LumaJingleSession: JingleSession {
// MARK: - Live WebRTC call
private final class LumaWebRTCCall: NSObject, @unchecked Sendable, RTCPeerConnectionDelegate {
private final class LumaWebRTCCall: NSObject, RTCPeerConnectionDelegate, @unchecked Sendable {
let id = UUID()
let startedAt = Date()
unowned let engine: LumaCallEngine
+7 -7
View File
@@ -6,17 +6,17 @@ import Martin
final class LumaRoomStore: RoomStore {
typealias Room = RoomBase
private let dispatcher = QueueDispatcher(label: "LumaRoomStore")
private let queue = DispatchQueue(label: "LumaRoomStore")
private var roomsByJID: [BareJID: RoomBase] = [:]
func rooms(for context: Context) -> [RoomBase] {
dispatcher.sync {
queue.sync {
Array(roomsByJID.values)
}
}
func room(for context: Context, with jid: BareJID) -> RoomBase? {
dispatcher.sync {
queue.sync {
roomsByJID[jid]
}
}
@@ -26,8 +26,8 @@ final class LumaRoomStore: RoomStore {
with jid: BareJID,
nickname: String,
password: String?
) -> ConversationCreateResult<RoomBase> {
dispatcher.sync {
) -> ConversationCreateResult {
queue.sync {
if let room = roomsByJID[jid] {
return .found(room)
}
@@ -36,7 +36,7 @@ final class LumaRoomStore: RoomStore {
jid: jid,
nickname: nickname,
password: password,
dispatcher: dispatcher
dispatcher: queue
)
roomsByJID[jid] = room
return .created(room)
@@ -44,7 +44,7 @@ final class LumaRoomStore: RoomStore {
}
func close(room: RoomBase) -> Bool {
dispatcher.sync {
queue.sync {
guard roomsByJID[room.jid] === room else { return false }
roomsByJID.removeValue(forKey: room.jid)
return true
+13 -7
View File
@@ -1838,7 +1838,7 @@ final class XMPPService {
makeMembersOnly: Bool
) async throws -> Bool {
let roomJID = JID(room.jid)
let configuration: JabberDataElement = try await withCheckedThrowingContinuation {
let configuration: DataForm = try await withCheckedThrowingContinuation {
continuation in
muc.getRoomConfiguration(roomJid: roomJID) { result in
switch result {
@@ -1849,25 +1849,31 @@ final class XMPPService {
}
var supportsNonAnonymousRooms = false
if let field: ListSingleField = configuration.getField(named: "muc#roomconfig_whois") {
if let field: DataForm.ListSingleField = configuration.getField(
named: "muc#roomconfig_whois")
{
field.value = "anyone"
supportsNonAnonymousRooms = true
} else if let field: TextSingleField = configuration.getField(named: "muc#roomconfig_whois")
} else if let field: DataForm.TextSingleField = configuration.getField(
named: "muc#roomconfig_whois")
{
field.value = "anyone"
supportsNonAnonymousRooms = true
}
if let field: ListMultiField = configuration.getField(named: "muc#roomconfig_getmemberlist")
if let field: DataForm.ListMultiField = configuration.getField(
named: "muc#roomconfig_getmemberlist")
{
field.value = Array(Set(field.value + ["moderator", "participant"])).sorted()
}
if makeMembersOnly,
let field: BooleanField = configuration.getField(named: "muc#roomconfig_membersonly")
let field: DataForm.BooleanField = configuration.getField(
named: "muc#roomconfig_membersonly")
{
field.value = true
}
if makeMembersOnly,
let field: BooleanField = configuration.getField(named: "muc#roomconfig_persistentroom")
let field: DataForm.BooleanField = configuration.getField(
named: "muc#roomconfig_persistentroom")
{
field.value = true
}
@@ -1876,7 +1882,7 @@ final class XMPPService {
(continuation: CheckedContinuation<Void, Error>) in
muc.setRoomConfiguration(roomJid: roomJID, configuration: configuration) { result in
switch result {
case .success(let value): continuation.resume(returning: value)
case .success: continuation.resume()
case .failure(let error): continuation.resume(throwing: error)
}
}