Skip to content

Commit 468a780

Browse files
committed
Fix typos in README and documentation
1 parent 0f8860f commit 468a780

File tree

3 files changed

+9
-6
lines changed

3 files changed

+9
-6
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ storage.removeExpiredObjects()
312312
[Storage](#storage) allows you to observe changes in the cache layer, both on
313313
a store and a key levels. The API lets you pass any object as an observer,
314314
while also passing an observation closure. The observation closure will be
315-
removed automatically when the weekly captured observer has been deallocated.
315+
removed automatically when the weakly captured observer has been deallocated.
316316

317317
## Storage observations
318318

Source/Shared/Storage/KeyObservationRegistry.swift

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ public protocol KeyObservationRegistry {
66

77
/**
88
Registers observation closure which will be removed automatically
9-
when the weekly captured observer has been deallocated.
10-
- Parameter observer: Any object that helps to determine if the observation is still valid
9+
when the weakly captured observer has been deallocated.
10+
- Parameter observer: Any object that helps determine if the observation is still valid
1111
- Parameter key: Unique key to identify the object in the cache
1212
- Parameter closure: Observation closure
1313
- Returns: Token used to cancel the observation and remove the observation closure
@@ -19,7 +19,10 @@ public protocol KeyObservationRegistry {
1919
closure: @escaping (O, S, KeyChange<S.T>) -> Void
2020
) -> ObservationToken
2121

22-
/// Removes observer by the given key.
22+
/**
23+
Removes observer by the given key.
24+
- Parameter key: Unique key to identify the object in the cache
25+
*/
2326
func removeObserver(forKey key: String)
2427

2528
/// Removes all registered key observers

Source/Shared/Storage/StorageObservationRegistry.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ public protocol StorageObservationRegistry {
66

77
/**
88
Registers observation closure which will be removed automatically
9-
when the weekly captured observer has been deallocated.
10-
- Parameter observer: Any object that helps to determine if the observation is still valid
9+
when the weakly captured observer has been deallocated.
10+
- Parameter observer: Any object that helps determine if the observation is still valid
1111
- Parameter closure: Observation closure
1212
- Returns: Token used to cancel the observation and remove the observation closure
1313
*/

0 commit comments

Comments
 (0)