Skip to content

Commit d573ca9

Browse files
committed
Swift proof v1
поправил некоторые формулировки, в т.ч. не нужно мн.ч. в словосочетаниях Files list -> file list, files group -> file group. в коде переменные конечно же не правил.
1 parent 461b305 commit d573ca9

File tree

3 files changed

+22
-21
lines changed

3 files changed

+22
-21
lines changed

Documentation/REST API.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,10 @@ let query = PaginationQuery()
3434
.stored(true)
3535
.ordering(.sizeDESC)
3636
.limit(5)
37-
// Make files list object
37+
// Make a list of files object
3838
let filesList = uploadcare.list()
3939

40-
// Get files list
40+
// Get file list
4141
filesList.get(withQuery: query) { (list, error) in
4242
if let error = error {
4343
print(error)
@@ -184,7 +184,7 @@ uploadcare.listOfGroups(withQuery: query) { (list, error) in
184184
print(list ?? "")
185185
}
186186

187-
// Using GroupsList object
187+
// Using a GroupsList object
188188
let groupsList = uploadcare.listOfGroups()
189189

190190
groupsList.get(withQuery: query) { (list, error) in
@@ -250,7 +250,7 @@ uploadcare.getProjectInfo { (project, error) in
250250

251251
## Secure delivery ([API Reference](https://uploadcare.com/docs/delivery/file_api/#authenticated-urls?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift)) ##
252252

253-
This method allows you to get an authenticated URL from your backend by using a redirect.
253+
This method allows you to get an authenticated URL from your backend by using redirect.
254254
To answer a request to that URL, your backend should generate an authenticated URL to your file and perform REDIRECT to a generated URL. A redirected URL will be caught and returned in the completion handler of that method.
255255

256256
Example: https://yourdomain.com/{UUID}/ — backend redirects to https://cdn.yourdomain.com/{uuid}/?token={token}&expire={timestamp}.
@@ -288,7 +288,7 @@ uploadcare.convertDocumentsWithSettings([task1, task2]) { (response, error) in
288288
}
289289
```
290290

291-
Alternatively you can pass custom "paths" param as array of strings (see ([documentation](https://uploadcare.com/docs/transformations/document_conversion/#convert-url-formatting?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift))):
291+
Alternatively, you can pass custom "paths" param as array of strings (see ([documentation](https://uploadcare.com/docs/transformations/document_conversion/#convert-url-formatting?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift))):
292292

293293
```swift
294294
uploadcare.convertDocuments([":uuid/document/-/format/:target-format/"]) { (response, error) in
@@ -347,7 +347,7 @@ uploadcare.convertVideosWithSettings([task1, task2]) { (response, error) in
347347
}
348348
```
349349

350-
Alternatively you can pass custom "paths" param as array of strings (see ([documentation](https://uploadcare.com/docs/transformations/video_encoding/#process-url-formatting?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift))):
350+
Alternatively, you can pass custom "paths" param as array of strings (see ([documentation](https://uploadcare.com/docs/transformations/video_encoding/#process-url-formatting?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift))):
351351

352352
```swift
353353
uploadcare.convertVideos([":uuid/video/-/format/ogg/"]) { (response, error) in

Documentation/Upload API.md

+9-8
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ fileForUploading1.upload(withName: "random_file_name.jpg", store: .store) { (res
3737
// Completion block is optional
3838
fileForUploading2?.upload(withName: "my_file.jpg", store: .store)
3939

40-
// Or you can just upload data and provide filename
40+
// Or you can just upload data and provide a filename
4141
let task = uploadcare.uploadAPI.upload(files: ["random_file_name.jpg": data], store: .store, expire: nil, { (progress) in
4242
print("upload progress: \(progress * 100)%")
4343
}) { (resultDictionary, error) in
@@ -58,12 +58,12 @@ task.cancel()
5858

5959
## Multipart uploads ([API Reference](https://uploadcare.com/api-refs/upload-api/#operation/multipartFileUploadStart/?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift)) ##
6060

61-
Multipart Uploads are useful when you are dealing with files larger than 100MB or explicitly want to accelerate uploads. Each Multipart Upload contains 3 steps:
61+
Multipart Uploads are useful when you are dealing with files larger than 100MB or you explicitly want to accelerate uploads. Each Multipart Upload contains 3 steps:
6262
1. Start transaction
6363
2. Upload file chunks concurrently
6464
3. Complete transaction
6565

66-
You can use this upload method which will run all 3 steps for you:
66+
You can use this upload method and it'll run all 3 steps for you:
6767

6868
```swift
6969
guard let url = Bundle.main.url(forResource: "Mona_Lisa_23mb", withExtension: "jpg") else { return }
@@ -88,6 +88,7 @@ task?.cancel()
8888

8989
// You can pause uploading
9090
task?.pause()
91+
9192
// To resume uploading
9293
task?.resume()
9394
```
@@ -124,7 +125,7 @@ let task3 = UploadFromURLTask(sourceUrl: url!)
124125

125126
## Check the status of a file uploaded from URL ([API Reference](https://uploadcare.com/api-refs/upload-api/#operation/fromURLUploadStatus/?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift)) ##
126127

127-
Use token that was recieved with Upload files from URLs method:
128+
Use a token recieved with Upload files from the URLs method:
128129

129130
```swift
130131
uploadcare.uploadAPI.uploadStatus(forToken: "UPLOAD_TOKEN") { (status, error) in
@@ -148,7 +149,7 @@ uploadcare.uploadAPI.fileInfo(withFileId: "FILE_UUID") { (file, error) in
148149
}
149150
```
150151

151-
## Create files group ([API Reference](https://uploadcare.com/api-refs/upload-api/#operation/createFilesGroup/?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift)) ##
152+
## Create file group ([API Reference](https://uploadcare.com/api-refs/upload-api/#operation/createFilesGroup/?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift)) ##
152153

153154
Uploadcare library provides 2 methods to create a group:
154155

@@ -165,7 +166,7 @@ self.uploadcare.uploadAPI.createFilesGroup(files: files) { (response, error) in
165166
}
166167
```
167168

168-
2. Provide an array of files UUIDs:
169+
2. Provide an array of file UUIDs:
169170

170171
```swift
171172
let filesIds: [String] = ["FILE_UUID1", "FILE_UUID2"]
@@ -192,6 +193,6 @@ uploadcare.uploadAPI.filesGroupInfo(groupId: "FILES_GROUP_ID") { (group, error)
192193

193194
## Secure uploads ([API Reference](https://uploadcare.com/docs/api_reference/upload/signed_uploads/?utm_source=github&utm_medium=referral&utm_campaign=uploadcare-swift)) ##
194195

195-
Requests signing works by default if secret key is provided during SDK initialization. SDK generates a signature internally. The signature is valid for 30 minutes. The new signature is generated automatically when the old one expires.
196+
Signing requests works by default if a Secret key is provided during SDK initialization. SDK generates a signature internally, and this signature stays valid for 30 minutes. New signatures are generated automatically when older ones expire.
196197

197-
Please notice that signed uploads should be enabled in your project’s settings in the [Uploadcare dashboard](https://uploadcare.com/dashboard/).
198+
Note that Signed Uploads should be enabled in the project’s settings in your [Uploadcare dashboard](https://uploadcare.com/dashboard/).

README.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
Uploadcare Swift API client for iOS, iPadOS, tvOS, macOS, and Linux handles uploads and further operations with files by wrapping Uploadcare Upload and REST APIs.
88

9-
Check out out [Demo App](/Demo).
9+
Check out our [Demo App](/Demo).
1010

1111
* [Installation](#installation)
1212
* [Initialization](#initialization)
@@ -44,7 +44,7 @@ To use a stable version, add a dependency to your Cartfile:
4444
github "uploadcare/uploadcare-swift" "0.1.0"
4545
```
4646

47-
To use current dev version:
47+
To use the current dev version:
4848

4949
```
5050
github "uploadcare/uploadcare-swift" "develop"
@@ -78,7 +78,7 @@ let uploadcare = Uploadcare(withPublicKey: "YOUR_PUBLIC_KEY", secretKey: "YOUR_S
7878

7979
## Using Upload API
8080

81-
Check full [Upload API documentation](https://github.com/uploadcare/uploadcare-swift/blob/master/Documentation/Upload%20API.md) for all available methods.
81+
Check the [Upload API documentation](https://github.com/uploadcare/uploadcare-swift/blob/master/Documentation/Upload%20API.md) to see all available methods.
8282

8383
Example of direct uploads:
8484

@@ -97,7 +97,7 @@ fileForUploading1.upload(withName: "random_file_name.jpg", store: .store) { (res
9797
// Completion block is optional
9898
fileForUploading2?.upload(withName: "my_file.jpg", store: .store)
9999

100-
// Or you can just upload data and provide filename
100+
// Or you can just upload data and provide a filename
101101
let task = uploadcare.uploadAPI.upload(files: ["random_file_name.jpg": data], store: .store, expire: nil, { (progress) in
102102
print("upload progress: \(progress * 100)%")
103103
}) { (resultDictionary, error) in
@@ -118,7 +118,7 @@ task.cancel()
118118

119119
## Using REST API
120120

121-
Check full [REST API documentation](https://github.com/uploadcare/uploadcare-swift/blob/master/Documentation/REST%20API.md) for all available methods.
121+
Refer to the [REST API documentation](https://github.com/uploadcare/uploadcare-swift/blob/master/Documentation/REST%20API.md) for all methods.
122122

123123
Example of getting list of files:
124124

@@ -128,10 +128,10 @@ let query = PaginationQuery()
128128
.stored(true)
129129
.ordering(.sizeDESC)
130130
.limit(5)
131-
// Make files list object
131+
// Make a list of files object
132132
let filesList = uploadcare.list()
133133

134-
// Get files list
134+
// Get file list
135135
filesList.get(withQuery: query) { (list, error) in
136136
if let error = error {
137137
print(error)

0 commit comments

Comments
 (0)