Skip to content

Commit

Permalink
Migrate from GRDB 5 to GRDB 6
Browse files Browse the repository at this point in the history
  • Loading branch information
iammajid committed Sep 18, 2024
1 parent dedf5cd commit 85ff0b9
Show file tree
Hide file tree
Showing 10 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/groue/GRDB.swift.git",
"state" : {
"revision" : "dd7e7f39e8e4d7a22d258d9809a882f914690b01",
"version" : "5.26.1"
"revision" : "2cf6c756e1e5ef6901ebae16576a7e4e4b834622",
"version" : "6.29.3"
}
},
{
Expand Down
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ let package = Package(
.package(url: "https://github.com/google/GTMAppAuth.git", .upToNextMinor(from: "4.0.0")),
.package(url: "https://github.com/google/gtm-session-fetcher.git", .upToNextMinor(from: "3.1.0")),
.package(url: "https://github.com/google/promises.git", .upToNextMinor(from: "2.3.0")),
.package(url: "https://github.com/groue/GRDB.swift.git", .upToNextMinor(from: "5.26.0")),
.package(url: "https://github.com/groue/GRDB.swift.git", .upToNextMinor(from: "6.29.1")),
.package(url: "https://github.com/openid/AppAuth-iOS.git", .upToNextMinor(from: "1.6.0")),
.package(url: "https://github.com/pCloud/pcloud-sdk-swift.git", .upToNextMinor(from: "3.2.0")),
.package(url: "https://github.com/phil1995/dropbox-sdk-obj-c-spm.git", .upToNextMinor(from: "7.2.0")),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class BoxIdentifierCache {
private let inMemoryDB: DatabaseQueue

init() throws {
self.inMemoryDB = DatabaseQueue()
self.inMemoryDB = try DatabaseQueue()
try inMemoryDB.write { db in
try db.create(table: BoxItem.databaseTableName) { table in
table.column(BoxItem.cloudPathKey, .text).notNull().primaryKey()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class DirectoryIdCache {
private let inMemoryDB: DatabaseQueue

init() throws {
self.inMemoryDB = DatabaseQueue()
self.inMemoryDB = try DatabaseQueue()
try inMemoryDB.write { db in
try db.create(table: CachedEntry.databaseTableName) { table in
table.column(CachedEntry.cleartextPathKey, .text).notNull().primaryKey()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class VaultFormat6ShortenedNameCache {
init(vaultPath: CloudPath) throws {
self.vaultPath = vaultPath
self.ciphertextNameCompIdx = vaultPath.pathComponents.lastItemIndex() + 4
self.inMemoryDB = DatabaseQueue()
self.inMemoryDB = try DatabaseQueue()
try inMemoryDB.write { db in
try db.create(table: CachedEntry.databaseTableName) { table in
table.column(CachedEntry.shortenedNameKey, .text).notNull().primaryKey()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ class VaultFormat7ShortenedNameCache {
self.vaultPath = vaultPath
self.threshold = threshold
self.ciphertextNameCompIdx = vaultPath.pathComponents.lastItemIndex() + 4
self.inMemoryDB = DatabaseQueue()
self.inMemoryDB = try DatabaseQueue()
try inMemoryDB.write { db in
try db.create(table: CachedEntry.databaseTableName) { table in
table.column(CachedEntry.shortenedNameKey, .text).notNull().primaryKey()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class GoogleDriveIdentifierCache {
private let inMemoryDB: DatabaseQueue

init() throws {
self.inMemoryDB = DatabaseQueue()
self.inMemoryDB = try DatabaseQueue()
try inMemoryDB.write { db in
try db.create(table: GoogleDriveItem.databaseTableName) { table in
table.column(GoogleDriveItem.cloudPathKey, .text).notNull().primaryKey()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class OneDriveIdentifierCache {
private let inMemoryDB: DatabaseQueue

init() throws {
self.inMemoryDB = DatabaseQueue()
self.inMemoryDB = try DatabaseQueue()
try inMemoryDB.write { db in
try db.create(table: OneDriveItem.databaseTableName) { table in
table.column(OneDriveItem.cloudPathKey, .text).notNull().primaryKey()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class PCloudIdentifierCache {
private let inMemoryDB: DatabaseQueue

init() throws {
self.inMemoryDB = DatabaseQueue()
self.inMemoryDB = try DatabaseQueue()
try inMemoryDB.write { db in
try db.create(table: PCloudItem.databaseTableName) { table in
table.column(PCloudItem.cloudPathKey, .text).notNull().primaryKey()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class DirectoryContentCacheTests: XCTestCase {
let subfolderPath = CloudPath("/subfolder")

override func setUpWithError() throws {
let inMemoryDB = DatabaseQueue()
let inMemoryDB = try DatabaseQueue()
cache = try DirectoryContentDBCache(dbWriter: inMemoryDB, maxPageSize: maxPageSize)
}

Expand Down

0 comments on commit 85ff0b9

Please sign in to comment.