Added NS_UNAVAILABLE to new/init

Summary:
Not sure what was expected for a "designated initialiser" feel free to school me and I'll do it!

(Also just had to google difference between + and - in ObjC)

Issue fixed: #654, #652
Closes https://github.com/Instagram/IGListKit/pull/662

Differential Revision: D4900092

Pulled By: jessesquires

fbshipit-source-id: 7858065ecc88a9ad7cb064811f0180d0f84f174d
This commit is contained in:
James Sherlock 2017-04-17 14:51:20 -07:00 committed by Facebook Github Bot
parent 63ed50c23c
commit df0e538119
2 changed files with 16 additions and 1 deletions

View file

@ -33,7 +33,17 @@ IGLK_SUBCLASSING_RESTRICTED
*/
- (instancetype)initWithCollectionViewTarget:(nullable id<UICollectionViewDelegate>)collectionViewTarget
scrollViewTarget:(nullable id<UIScrollViewDelegate>)scrollViewTarget
interceptor:(IGListAdapter *)interceptor;
interceptor:(IGListAdapter *)interceptor NS_DESIGNATED_INITIALIZER;
/**
:nodoc:
*/
- (instancetype)init NS_UNAVAILABLE;
/**
:nodoc:
*/
+ (instancetype)new NS_UNAVAILABLE;
@end

View file

@ -107,6 +107,11 @@ IGLK_SUBCLASSING_RESTRICTED
*/
- (instancetype)init NS_UNAVAILABLE;
/**
:nodoc:
*/
+ (instancetype)new NS_UNAVAILABLE;
@end
NS_ASSUME_NONNULL_END