From 8f67eed60fe93a7eb50a9a9fbec6e1825276bbd2 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Mon, 14 Jun 2021 23:09:50 +0200 Subject: [PATCH] Fix typos in class and file names --- Mastodon.xcodeproj/project.pbxproj | 8 ++++---- .../xcshareddata/swiftpm/Package.resolved | 2 +- Mastodon/Extension/CoreDataStack/Emojis.swift | 4 ++-- Mastodon/Extension/CoreDataStack/Fields.swift | 4 ++-- Mastodon/Service/APIService/APIService+Media.swift | 2 +- Mastodon/Service/APIService/APIService+UserTimeline.swift | 2 +- .../MastodonAttachmentService+UploadState.swift | 2 +- ...eoPlaybackService.swift => VideoPlaybackService.swift} | 0 .../Sources/MastodonSDK/API/Mastodon+API+Account.swift | 6 +++--- .../Sources/MastodonSDK/API/Mastodon+API+Media.swift | 4 ++-- 10 files changed, 17 insertions(+), 17 deletions(-) rename Mastodon/Service/{ViedeoPlaybackService.swift => VideoPlaybackService.swift} (100%) diff --git a/Mastodon.xcodeproj/project.pbxproj b/Mastodon.xcodeproj/project.pbxproj index 5d765861..1c2008ce 100644 --- a/Mastodon.xcodeproj/project.pbxproj +++ b/Mastodon.xcodeproj/project.pbxproj @@ -169,7 +169,7 @@ 5DDDF1932617442700311060 /* Mastodon+Entity+Account.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5DDDF1922617442700311060 /* Mastodon+Entity+Account.swift */; }; 5DDDF1992617447F00311060 /* Mastodon+Entity+Tag.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5DDDF1982617447F00311060 /* Mastodon+Entity+Tag.swift */; }; 5DDDF1A92617489F00311060 /* Mastodon+Entity+History.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5DDDF1A82617489F00311060 /* Mastodon+Entity+History.swift */; }; - 5DF1054125F886D400D6C0D4 /* ViedeoPlaybackService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5DF1054025F886D400D6C0D4 /* ViedeoPlaybackService.swift */; }; + 5DF1054125F886D400D6C0D4 /* VideoPlaybackService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5DF1054025F886D400D6C0D4 /* VideoPlaybackService.swift */; }; 5DF1054725F8870E00D6C0D4 /* VideoPlayerViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5DF1054625F8870E00D6C0D4 /* VideoPlayerViewModel.swift */; }; 5DF1056425F887CB00D6C0D4 /* AVPlayer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5DF1056325F887CB00D6C0D4 /* AVPlayer.swift */; }; 5DF1057925F88A1D00D6C0D4 /* PlayerContainerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5DF1057825F88A1D00D6C0D4 /* PlayerContainerView.swift */; }; @@ -734,7 +734,7 @@ 5DDDF1922617442700311060 /* Mastodon+Entity+Account.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Mastodon+Entity+Account.swift"; sourceTree = ""; }; 5DDDF1982617447F00311060 /* Mastodon+Entity+Tag.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Mastodon+Entity+Tag.swift"; sourceTree = ""; }; 5DDDF1A82617489F00311060 /* Mastodon+Entity+History.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Mastodon+Entity+History.swift"; sourceTree = ""; }; - 5DF1054025F886D400D6C0D4 /* ViedeoPlaybackService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViedeoPlaybackService.swift; sourceTree = ""; }; + 5DF1054025F886D400D6C0D4 /* VideoPlaybackService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VideoPlaybackService.swift; sourceTree = ""; }; 5DF1054625F8870E00D6C0D4 /* VideoPlayerViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VideoPlayerViewModel.swift; sourceTree = ""; }; 5DF1056325F887CB00D6C0D4 /* AVPlayer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AVPlayer.swift; sourceTree = ""; }; 5DF1057825F88A1D00D6C0D4 /* PlayerContainerView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PlayerContainerView.swift; sourceTree = ""; }; @@ -1347,7 +1347,7 @@ DB4563BC25E11A24004DA0B9 /* KeyboardResponderService.swift */, 2D206B8B25F6015000143C56 /* AudioPlaybackService.swift */, 2DA6054625F716A2006356F9 /* PlaybackState.swift */, - 5DF1054025F886D400D6C0D4 /* ViedeoPlaybackService.swift */, + 5DF1054025F886D400D6C0D4 /* VideoPlaybackService.swift */, DB71FD4B25F8C80E00512AE1 /* StatusPrefetchingService.swift */, DBC7A67B260DFADE00E57475 /* StatusPublishService.swift */, 2D9DB966263A76FB007C1D71 /* BlockDomainService.swift */, @@ -2961,7 +2961,7 @@ DBBF1DC7265251D400E5B703 /* AutoCompleteViewModel+State.swift in Sources */, DBCC3B9526157E6E0045B23D /* APIService+Relationship.swift in Sources */, 2D7631B325C159F700929FB9 /* Item.swift in Sources */, - 5DF1054125F886D400D6C0D4 /* ViedeoPlaybackService.swift in Sources */, + 5DF1054125F886D400D6C0D4 /* VideoPlaybackService.swift in Sources */, DB6B35182601FA3400DC1E11 /* MastodonAttachmentService.swift in Sources */, 0FB3D2F725E4C24D00AAD544 /* MastodonPickServerViewModel.swift in Sources */, 2D61335E25C1894B00CAE157 /* APIService.swift in Sources */, diff --git a/Mastodon.xcworkspace/xcshareddata/swiftpm/Package.resolved b/Mastodon.xcworkspace/xcshareddata/swiftpm/Package.resolved index 296feea2..cad5ea61 100644 --- a/Mastodon.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/Mastodon.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -69,7 +69,7 @@ "repositoryURL": "https://github.com/onevcat/Kingfisher.git", "state": { "branch": null, - "revision": "15d199e84677303a7004ed2c5ecaa1a90f3863f8", + "revision": "bbc4bc4def7eb05a7ba8e1219f80ee9be327334e", "version": "6.2.1" } }, diff --git a/Mastodon/Extension/CoreDataStack/Emojis.swift b/Mastodon/Extension/CoreDataStack/Emojis.swift index 87ae5017..a35e2630 100644 --- a/Mastodon/Extension/CoreDataStack/Emojis.swift +++ b/Mastodon/Extension/CoreDataStack/Emojis.swift @@ -8,11 +8,11 @@ import Foundation import MastodonSDK -protocol EmojiContinaer { +protocol EmojiContainer { var emojisData: Data? { get } } -extension EmojiContinaer { +extension EmojiContainer { static func encode(emojis: [Mastodon.Entity.Emoji]) -> Data? { return try? JSONEncoder().encode(emojis) diff --git a/Mastodon/Extension/CoreDataStack/Fields.swift b/Mastodon/Extension/CoreDataStack/Fields.swift index 795863f8..5674c08b 100644 --- a/Mastodon/Extension/CoreDataStack/Fields.swift +++ b/Mastodon/Extension/CoreDataStack/Fields.swift @@ -8,11 +8,11 @@ import Foundation import MastodonSDK -protocol FieldContinaer { +protocol FieldContainer { var fieldsData: Data? { get } } -extension FieldContinaer { +extension FieldContainer { static func encode(fields: [Mastodon.Entity.Field]) -> Data? { return try? JSONEncoder().encode(fields) diff --git a/Mastodon/Service/APIService/APIService+Media.swift b/Mastodon/Service/APIService/APIService+Media.swift index 03e33342..1fffb5a6 100644 --- a/Mastodon/Service/APIService/APIService+Media.swift +++ b/Mastodon/Service/APIService/APIService+Media.swift @@ -13,7 +13,7 @@ extension APIService { func uploadMedia( domain: String, - query: Mastodon.API.Media.UploadMeidaQuery, + query: Mastodon.API.Media.UploadMediaQuery, mastodonAuthenticationBox: AuthenticationService.MastodonAuthenticationBox ) -> AnyPublisher, Error> { let authorization = mastodonAuthenticationBox.userAuthorization diff --git a/Mastodon/Service/APIService/APIService+UserTimeline.swift b/Mastodon/Service/APIService/APIService+UserTimeline.swift index cb20c85e..0e1e223b 100644 --- a/Mastodon/Service/APIService/APIService+UserTimeline.swift +++ b/Mastodon/Service/APIService/APIService+UserTimeline.swift @@ -27,7 +27,7 @@ extension APIService { ) -> AnyPublisher, Error> { let authorization = authorizationBox.userAuthorization let requestMastodonUserID = authorizationBox.userID - let query = Mastodon.API.Account.AccountStatuseseQuery( + let query = Mastodon.API.Account.AccountStatusesQuery( maxID: maxID, sinceID: sinceID, excludeReplies: excludeReplies, diff --git a/Mastodon/Service/MastodonAttachmentService/MastodonAttachmentService+UploadState.swift b/Mastodon/Service/MastodonAttachmentService/MastodonAttachmentService+UploadState.swift index 23233ec3..b154d17c 100644 --- a/Mastodon/Service/MastodonAttachmentService/MastodonAttachmentService+UploadState.swift +++ b/Mastodon/Service/MastodonAttachmentService/MastodonAttachmentService+UploadState.swift @@ -56,7 +56,7 @@ extension MastodonAttachmentService.UploadState { guard let file = service.file.value else { return } let description = service.description.value - let query = Mastodon.API.Media.UploadMeidaQuery( + let query = Mastodon.API.Media.UploadMediaQuery( file: file, thumbnail: nil, description: description, diff --git a/Mastodon/Service/ViedeoPlaybackService.swift b/Mastodon/Service/VideoPlaybackService.swift similarity index 100% rename from Mastodon/Service/ViedeoPlaybackService.swift rename to Mastodon/Service/VideoPlaybackService.swift diff --git a/MastodonSDK/Sources/MastodonSDK/API/Mastodon+API+Account.swift b/MastodonSDK/Sources/MastodonSDK/API/Mastodon+API+Account.swift index d1c5458c..0ca985b0 100644 --- a/MastodonSDK/Sources/MastodonSDK/API/Mastodon+API+Account.swift +++ b/MastodonSDK/Sources/MastodonSDK/API/Mastodon+API+Account.swift @@ -71,14 +71,14 @@ extension Mastodon.API.Account { /// - Parameters: /// - session: `URLSession` /// - domain: Mastodon instance domain. e.g. "example.com" - /// - query: `AccountStatuseseQuery` with query parameters + /// - query: `AccountStatusesQuery` with query parameters /// - authorization: User token /// - Returns: `AnyPublisher` contains `Token` nested in the response public static func statuses( session: URLSession, domain: String, accountID: Mastodon.Entity.Account.ID, - query: AccountStatuseseQuery, + query: AccountStatusesQuery, authorization: Mastodon.API.OAuth.Authorization ) -> AnyPublisher, Error> { let request = Mastodon.API.get( @@ -94,7 +94,7 @@ extension Mastodon.API.Account { .eraseToAnyPublisher() } - public struct AccountStatuseseQuery: GetQuery { + public struct AccountStatusesQuery: GetQuery { public let maxID: Mastodon.Entity.Status.ID? public let sinceID: Mastodon.Entity.Status.ID? public let excludeReplies: Bool? // undocumented diff --git a/MastodonSDK/Sources/MastodonSDK/API/Mastodon+API+Media.swift b/MastodonSDK/Sources/MastodonSDK/API/Mastodon+API+Media.swift index 0918cbd0..a292df6a 100644 --- a/MastodonSDK/Sources/MastodonSDK/API/Mastodon+API+Media.swift +++ b/MastodonSDK/Sources/MastodonSDK/API/Mastodon+API+Media.swift @@ -33,7 +33,7 @@ extension Mastodon.API.Media { public static func uploadMedia( session: URLSession, domain: String, - query: UploadMeidaQuery, + query: UploadMediaQuery, authorization: Mastodon.API.OAuth.Authorization? ) -> AnyPublisher, Error> { var request = Mastodon.API.post( @@ -56,7 +56,7 @@ extension Mastodon.API.Media { .eraseToAnyPublisher() } - public struct UploadMeidaQuery: PostQuery, PutQuery { + public struct UploadMediaQuery: PostQuery, PutQuery { public let file: Mastodon.Query.MediaAttachment? public let thumbnail: Mastodon.Query.MediaAttachment? public let description: String?