From bf26664703caff763c263372b04e20a7ba3dbd1c Mon Sep 17 00:00:00 2001 From: Anass Bouassaba Date: Sun, 24 Nov 2024 12:32:50 +0100 Subject: [PATCH] chore: code formating adjustments --- Sources/File.swift | 12 +++++------- Sources/Mosaic.swift | 6 +++--- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/Sources/File.swift b/Sources/File.swift index d5b840e..9350691 100644 --- a/Sources/File.swift +++ b/Sources/File.swift @@ -552,25 +552,23 @@ public struct VOFile { } public func urlForOriginal(_ id: String, fileExtension: String) -> URL { - URL(string: "\(urlForID(id))/original.\(fileExtension)?" + "access_token=\(accessToken)")! + URL(string: "\(urlForID(id))/original.\(fileExtension)?access_token=\(accessToken)")! } public func urlForPreview(_ id: String, fileExtension: String) -> URL { - URL(string: "\(urlForID(id))/preview.\(fileExtension)?" + "access_token=\(accessToken)")! + URL(string: "\(urlForID(id))/preview.\(fileExtension)?access_token=\(accessToken)")! } public func urlForThumbnail(_ id: String, fileExtension: String) -> URL { - URL(string: "\(urlForID(id))/thumbnail.\(fileExtension)?" + "access_token=\(accessToken)")! + URL(string: "\(urlForID(id))/thumbnail.\(fileExtension)?access_token=\(accessToken)")! } public func urlForSegmentedPage(_ id: String, page: Int, fileExtension: String) -> URL { - URL(string: "\(urlForID(id))/segmentation/pages/\(page).\(fileExtension)?" + "access_token=\(accessToken)")! + URL(string: "\(urlForID(id))/segmentation/pages/\(page).\(fileExtension)?access_token=\(accessToken)")! } public func urlForSegmentedThumbnail(_ id: String, page: Int, fileExtension: String) -> URL { - // swift-format-ignore - // swiftlint:disable:next line_length - URL(string: "\(urlForID(id))/segmentation/thumbnails/\(page).\(fileExtension)?" + "access_token=\(accessToken)")! + URL(string: "\(urlForID(id))/segmentation/thumbnails/\(page).\(fileExtension)?access_token=\(accessToken)")! } public func urlForUserPermissions(_ id: String) -> URL { diff --git a/Sources/Mosaic.swift b/Sources/Mosaic.swift index 12e41c3..301144b 100644 --- a/Sources/Mosaic.swift +++ b/Sources/Mosaic.swift @@ -124,9 +124,9 @@ public struct VOMosaic { column: Int, fileExtension: String ) -> URL { - URL( - string: "\(urlForFile(id))/zoom_level/\(zoomLevel.index)" - + "/row/\(row)/column/\(column)/extension/\(fileExtension)?" + "access_token=\(accessToken)")! + // swift-format-ignore + // swiftlint:disable:next line_length + URL(string: "\(urlForFile(id))/zoom_level/\(zoomLevel.index)/row/\(row)/column/\(column)/extension/\(fileExtension)?access_token=\(accessToken)")! } // MARK: - Types