Skip to content

Commit

Permalink
Make naming more explicit
Browse files Browse the repository at this point in the history
  • Loading branch information
nielsandriesse committed Jun 10, 2020
1 parent 62a5cdf commit a193200
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions SignalServiceKit/src/Loki/Database/Storage.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import PromiseKit

@objc(LKStorage)
public final class Storage : NSObject {
private static let queue = DispatchQueue(label: "Storage.queue", qos: .userInitiated)
public static let serialQueue = DispatchQueue(label: "Storage.serialQueue", qos: .userInitiated)

private static var owsStorage: OWSPrimaryStorage { OWSPrimaryStorage.shared() }

Expand Down Expand Up @@ -39,7 +39,7 @@ public final class Storage : NSObject {

public static func write(with block: @escaping (YapDatabaseReadWriteTransaction) -> Void) -> Promise<Void> {
let (promise, seal) = Promise<Void>.pending()
queue.async { // TODO: There are cases where this isn't necessary
serialQueue.async { // TODO: There are cases where this isn't necessary
owsStorage.dbReadWriteConnection.readWrite(block)
seal.fulfill(())
}
Expand Down

0 comments on commit a193200

Please sign in to comment.