Skip to content

Commit 1a546ad

Browse files
committed
review
1 parent c30f761 commit 1a546ad

File tree

4 files changed

+10
-11
lines changed

4 files changed

+10
-11
lines changed

FirebaseStorage/Tests/Unit/FIRStorageTestHelpers.m

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
#import "FirebaseStorage/Tests/Unit/FIRStorageTestHelpers.h"
1616
#import "FirebaseStorage/Sources/Public/FirebaseStorage/FIRStorage.h"
1717

18-
//#import "FirebaseStorage/Sources/FIRStorageComponent.h"
1918
#import "SharedTestUtilities/FIRComponentTestUtilities.h"
2019

2120
NSString *const kGoogleHTTPErrorDomain = @"com.google.HTTPStatus";

FirebaseStorageSwift/Sources/Storage.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ import FirebaseAuthInterop
4242
@objc(storageForApp:) open class func storage(app: FirebaseApp = FirebaseApp.app()!) -> Storage {
4343
let provider = ComponentType<StorageProvider>.instance(for: StorageProvider.self,
4444
in: app.container)
45-
return provider.Storage(for: FIRIMPLStorage.bucket(for: app))
45+
return provider.storage(for: FIRIMPLStorage.bucket(for: app))
4646
}
4747

4848
/**
@@ -57,7 +57,7 @@ import FirebaseAuthInterop
5757
url: String) -> Storage {
5858
let provider = ComponentType<StorageProvider>.instance(for: StorageProvider.self,
5959
in: app.container)
60-
return provider.Storage(for: FIRIMPLStorage.bucket(for: app, url: url))
60+
return provider.storage(for: FIRIMPLStorage.bucket(for: app, url: url))
6161
}
6262

6363
/**

FirebaseStorageSwift/Sources/StorageComponent.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import FirebaseCoreInternal
2020

2121
@objc(FIRStorageProvider)
2222
protocol StorageProvider {
23-
@objc func Storage(for bucket: String) -> Storage
23+
@objc func storage(for bucket: String) -> Storage
2424
// TODO: See if we can avoid the `type` parameter by either making it a `Storage` argument to
2525
// allow subclasses, or avoid it entirely and fix tests. This was done for StorageCombineUnit,
2626
// although we may be able to now port to using `@testable` instead of using the mock.
@@ -64,7 +64,7 @@ protocol StorageProvider {
6464

6565
// MARK: - StorageProvider conformance
6666

67-
func Storage(for bucket: String) -> Storage {
67+
func storage(for bucket: String) -> Storage {
6868
os_unfair_lock_lock(&instancesLock)
6969

7070
// Unlock before the function returns.

FirebaseStorageSwift/Sources/StorageReference.swift

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,8 @@ import FirebaseStorageObjC
9999
* about the object being uploaded.
100100
* @return An instance of StorageUploadTask, which can be used to monitor or manage the upload.
101101
*/
102-
@objc(putData:metadata:) @discardableResult
102+
@objc(putData:metadata:)
103+
@discardableResult
103104
open func putData(_ uploadData: Data, metadata: StorageMetadata? = nil) -> StorageUploadTask {
104105
return StorageUploadTask(impl.put(uploadData, metadata: metadata?.impl))
105106
}
@@ -356,6 +357,10 @@ import FirebaseStorageObjC
356357

357358
// MARK: - Delete
358359

360+
/**
361+
* Deletes the object at the current path.
362+
* @param completion A completion block which returns nil on success, or an error on failure.
363+
*/
359364
@objc(deleteWithCompletion:)
360365
open func delete(completion: ((_: Error?) -> Void)?) {
361366
impl.delete(completion: completion)
@@ -382,11 +387,6 @@ import FirebaseStorageObjC
382387
return impl.description
383388
}
384389

385-
/**
386-
* Deletes the object at the current path.
387-
* @param completion A completion block which returns nil on success, or an error on failure.
388-
*/
389-
390390
// MARK: - Internal APIs
391391

392392
private let impl: FIRIMPLStorageReference

0 commit comments

Comments
 (0)