File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change 1111
1212#import < Parse/PFObject.h>
1313#import < Parse/PFSubclassing.h>
14+ #import < Parse/PFUser.h>
1415
1516NS_ASSUME_NONNULL_BEGIN
1617
18+ @class PFRelation<ObjectType : PFObject *>;
19+
1720/* *
1821 The `PFRole` class represents a Role on the Parse server.
1922 `PFRoles` represent groupings of `PFUser` objects for the purposes of granting permissions
@@ -83,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN
8386 (e.g. read or write access through ACLs). You can add or remove users from
8487 the role through this relation.
8588 */
86- @property (nonatomic , strong , readonly ) PFRelation *users;
89+ @property (nonatomic , strong , readonly ) PFRelation<PFUser *> *users;
8790
8891/* *
8992 Gets the `PFRelation` for the `PFRole` objects that are direct children of this role.
@@ -92,7 +95,7 @@ NS_ASSUME_NONNULL_BEGIN
9295 (e.g. read or write access through ACLs). You can add or remove child roles
9396 from this role through this relation.
9497 */
95- @property (nonatomic , strong , readonly ) PFRelation *roles;
98+ @property (nonatomic , strong , readonly ) PFRelation<PFRole *> *roles;
9699
97100@end
98101
Original file line number Diff line number Diff line change @@ -51,11 +51,11 @@ + (instancetype)roleWithName:(NSString *)name acl:(PFACL *)acl {
5151@dynamic name;
5252
5353// Dynamic synthesizers would use objectForKey, not relationForKey
54- - (PFRelation *)roles {
54+ - (PFRelation<PFRole *> *)roles {
5555 return [self relationForKey: @keypath (PFRole, roles)];
5656}
5757
58- - (PFRelation *)users {
58+ - (PFRelation<PFUser *> *)users {
5959 return [self relationForKey: @keypath (PFRole, users)];
6060}
6161
You can’t perform that action at this time.
0 commit comments