8000 discard @discardableResult change · firebase/firebase-ios-sdk@e2b4a7f · GitHub
[go: up one dir, main page]

Skip to content

Commit e2b4a7f

Browse files
committed
discard @discardableResult change
1 parent 3d394e8 commit e2b4a7f

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

FirebaseStorage/Sources/AsyncAwait.swift

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ import Foundation
4848
/// - Throws:
4949
/// - An error if the operation failed, for example if Storage was unreachable.
5050
/// - Returns: StorageMetadata with additional information about the object being uploaded.
51-
@discardableResult
5251
func putDataAsync(_ uploadData: Data,
5352
metadata: StorageMetadata? = nil,
5453
onProgress: ((Progress?) -> Void)? = nil) async throws -> StorageMetadata {
@@ -86,7 +85,6 @@ import Foundation
8685
/// - Throws:
8786
/// - An error if the operation failed, for example if no file was present at the specified `url`.
8887
/// - Returns: `StorageMetadata` with additional information about the object being uploaded.
89-
@discardableResult
9088
func putFileAsync(from url: URL,
9189
metadata: StorageMetadata? = nil,
9290
onProgress: ((Progress?) -> Void)? = nil) async throws -> StorageMetadata {
@@ -122,7 +120,6 @@ import Foundation
122120
/// - An error if the operation failed, for example if Storage was unreachable
123121
/// or `fileURL` did not reference a valid path on disk.
124122
/// - Returns: A `URL` pointing to the file path of the downloaded file.
125-
@discardableResult
126123
func writeAsync(toFile fileURL: URL,
127124
onProgress: ((Progress?) -> Void)? = nil) async throws -> URL {
128125
guard let onProgress else {

FirebaseStorage/Tests/Integration/StorageAsyncAwait.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ import XCTest
270270
let data = try XCTUnwrap("Hello Swift World".data(using: .utf8), "Data construction failed")
271271

272272
Task {
273-
try await ref.putDataAsync(data)
273+
let _ = try await ref.putDataAsync(data)
274274
let task = ref.write(toFile: fileURL)
275275

276276
task.observe(StorageTaskStatus.success) { snapshot in

0 commit comments

Comments
 (0)
0