Skip to content
This repository was archived by the owner on Feb 2, 2023. It is now read-only.

Commit a59a0f0

Browse files
author
Hannah Troisi
authored
don't allow nil background / overlay layout elements (#2795)
1 parent 3b2e53f commit a59a0f0

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

AsyncDisplayKit/Layout/ASBackgroundLayoutSpec.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@ NS_ASSUME_NONNULL_BEGIN
2020
/**
2121
* Background layoutElement for this layout spec
2222
*/
23-
@property (nullable, nonatomic, strong) id<ASLayoutElement> background;
23+
@property (nonatomic, strong) id<ASLayoutElement> background;
2424

2525
/**
2626
* Creates and returns an ASBackgroundLayoutSpec object
2727
*
2828
* @param child A child that is laid out to determine the size of this spec.
29-
* @param background A layoutElement object that is laid out behind the child. If this is nil, the background is omitted.
29+
* @param background A layoutElement object that is laid out behind the child.
3030
*/
31-
+ (instancetype)backgroundLayoutSpecWithChild:(id<ASLayoutElement>)child background:(nullable id<ASLayoutElement>)background AS_WARN_UNUSED_RESULT;
31+
+ (instancetype)backgroundLayoutSpecWithChild:(id<ASLayoutElement>)child background:(id<ASLayoutElement>)background AS_WARN_UNUSED_RESULT;
3232

3333
@end
3434

AsyncDisplayKit/Layout/ASOverlayLayoutSpec.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@ NS_ASSUME_NONNULL_BEGIN
2020
/**
2121
* Overlay layoutElement of this layout spec
2222
*/
23-
@property (nullable, nonatomic, strong) id<ASLayoutElement> overlay;
23+
@property (nonatomic, strong) id<ASLayoutElement> overlay;
2424

2525
/**
2626
* Creates and returns an ASOverlayLayoutSpec object with a given child and an layoutElement that act as overlay.
2727
*
2828
* @param child A child that is laid out to determine the size of this spec.
29-
* @param overlay A layoutElement object that is laid out over the child. If this is nil, the overlay is omitted.
29+
* @param overlay A layoutElement object that is laid out over the child.
3030
*/
31-
+ (instancetype)overlayLayoutSpecWithChild:(id<ASLayoutElement>)child overlay:(nullable id<ASLayoutElement>)overlay AS_WARN_UNUSED_RESULT;
31+
+ (instancetype)overlayLayoutSpecWithChild:(id<ASLayoutElement>)child overlay:(id<ASLayoutElement>)overlay AS_WARN_UNUSED_RESULT;
3232

3333
@end
3434

0 commit comments

Comments
 (0)