Skip to content

Commit 44d5a0e

Browse files
committed
Remove trailing whitespaces.
1 parent 03a0b0b commit 44d5a0e

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

Interop/Firebase Component System.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ the Interop system. Both SDKs depend on a shared protocol that describes the fun
1515
by one SDK and required by the other. Let's use `A` and `B`, where `B` depends on functionality
1616
provided by `A` and the functionality is described by protocol `AInterop`.
1717

18-
During configuration, `A` tells Core that it provides functionality for `AInterop` and `B` tells
18+
During configuration, `A` tells Core that it provides functionality for `AInterop` and `B` tells
1919
Core it would like functionality `AInterop` (and specifies whether it is required or optional) as
2020
well as how to instantiate an instance of `B`. When a developer requests `B`, FirebaseCore
2121
instantiates `B` and passes a container that contains the instance of `A` that provides `AInterop`.
@@ -126,7 +126,7 @@ that it uses to register with the container. Using Functions as an example:
126126
@implementation FIRFunctions
127127
128128
+ (void)load {
129-
[FIRComponentContainer registerAsComponentRegistrant:self];
129+
[FIRComponentContainer registerAsComponentRegistrant:self];
130130
}
131131
132132
/// The array of components to register with Core. Since Functions is a leaf node and
@@ -146,7 +146,7 @@ that it uses to register with the container. Using Functions as an example:
146146
};
147147
148148
// Create the component that can create instances of `FIRFunctions`.
149-
FIRComponent *internalProvider =
149+
FIRComponent *internalProvider =
150150
[FIRComponent componentWithProtocol:@protocol(FIRFunctionsInstanceProvider)
151151
creationBlock:creationBlock];
152152
@@ -158,13 +158,13 @@ that it uses to register with the container. Using Functions as an example:
158158
// Get the instance from the `FIRApp`'s container. This will create a new instance the
159159
// first time it is called, and since `isCacheable` is set in the component creation
160160
// block, it will return the existing instance on subsequent calls.
161-
id<FIRFunctionsInstanceProvider> instance =
161+
id<FIRFunctionsInstanceProvider> instance =
162162
FIR_COMPONENT(FIRFunctionsInstanceProvider, app.container);
163163
164164
// In the component creation block, we return an instance of `FIRFunctions`. Cast it and
165165
// return it.
166166
return (FIRFunctions *)instance;
167-
}
167+
}
168168
169169
// ... Other `FIRFunctions` methods.
170170
@@ -201,7 +201,7 @@ could conform to and provide to other SDKs:
201201
*isCacheable = YES;
202202
return [[FIRAuth alloc] initWithApp:container.app];
203203
};
204-
FIRComponent *authInterop =
204+
FIRComponent *authInterop =
205205
[FIRComponent componentWithProtocol:@protocol(FIRAuthInteroperable)
206206
creationBlock:authCreationBlock];
207207
return @[authInterop];
@@ -264,7 +264,7 @@ separate class to keep `Firestore.m` cleaner.
264264
265265
+ (void)load {
266266
// Don't forget to register!
267-
[FIRComponentContainer registerAsComponentRegistrant:self];
267+
[FIRComponentContainer registerAsComponentRegistrant:self];
268268
}
269269
270270
- (instancetype)initWithApp:(FIRApp *)app {
@@ -332,12 +332,12 @@ Before adding the dependency on `FIRAuthInterop`.
332332
return [[FIRFunctions alloc] initWithApp:container.app];
333333
};
334334
335-
FIRComponent *internalProvider =
335+
FIRComponent *internalProvider =
336336
[FIRComponent componentWithProtocol:@protocol(FIRFunctionsInstanceProvider)
337337
creationBlock:creationBlock];
338338
339339
return @[ internalProvider ];
340-
}
340+
}
341341
```
342342

343343
After adding the dependency on `FIRAuthInterop`. See comments with "ADDED:".
@@ -350,7 +350,7 @@ After adding the dependency on `FIRAuthInterop`. See comments with "ADDED:".
350350
351351
// ADDED: Retrieve an instance that conforms to `FIRAuthInterop` from the container.
352352
id<FIRAuthInterop> auth = FIR_COMPONENT(FIRAuthInterop, container);
353-
353+
354354
// ADDED: Note the constructor has a new parameter: auth. It's good practice to inject
355355
// the instance needed in the constructor instead of pulling it from the app
356356
// passed in. This allows for better unit testing with fakes since any object
@@ -360,7 +360,7 @@ After adding the dependency on `FIRAuthInterop`. See comments with "ADDED:".
360360
361361
// ADDED: Define a dependency on the `FIRAuthInteroperable` protocol. Declare if the
362362
// dependency is required or not.
363-
FIRDependency *auth =
363+
FIRDependency *auth =
364364
[FIRDependency dependencyWithProtocol:@protocol(FIRAuthInteroperable)
365365
isRequired:NO];
366366
@@ -376,7 +376,7 @@ After adding the dependency on `FIRAuthInterop`. See comments with "ADDED:".
376376
creationBlock:creationBlock];
377377
378378
return @[ internalProvider ];
379-
}
379+
}
380380
```
381381

382382
Based on the new constructor, Functions can now use the `auth` instance as defined by the
@@ -420,7 +420,7 @@ An abbreviated code sample:
420420
};
421421
422422
// Declare a self dependency on the combined interop component.
423-
FIRDependency *auth =
423+
FIRDependency *auth =
424424
[FIRDependency dependencyWithProtocol:@protocol(FIRAuthCombinedInterop)
425425
isRequired:YES];
426426
@@ -431,19 +431,19 @@ An abbreviated code sample:
431431
432432
// Both the user and sign in components depend on the previous component as
433433
// declared in the dependency above.
434-
434+
435435
FIRComponent *userComponent =
436436
[FIRComponent componentWithProtocol:@protocol(FIRAuthUserInterop)
437437
instantiationTiming:FIRInstantiationTimingLazy
438438
dependencies:@[ auth ]
439439
creationBlock:combinedBlock];
440-
440+
441441
FIRComponent *signInComponent =
442442
[FIRComponent componentWithProtocol:@protocol(FIRAuthSignInInterop)
443443
instantiationTiming:FIRInstantiationTimingLazy
444444
dependencies:@[ auth ]
445445
creationBlock:combinedBlock];
446446
447447
return @[ authComponent, userComponent, signInComponent ];
448-
}
448+
}
449449
```

0 commit comments

Comments
 (0)