IOSAD-72 adapt ratingFromString to usual PEPInternalSession trampoline
authorDirk Zimmermann <dirk@pep-project.org>
Thu, 12 Apr 2018 07:15:42 +0200
changeset 5661242b57ef5e6
parent 565 9ff3a0bfc8f6
child 567 b9439926c09f
IOSAD-72 adapt ratingFromString to usual PEPInternalSession trampoline
pEpObjCAdapter/PEPSession.m
     1.1 --- a/pEpObjCAdapter/PEPSession.m	Thu Apr 12 07:15:41 2018 +0200
     1.2 +++ b/pEpObjCAdapter/PEPSession.m	Thu Apr 12 07:15:42 2018 +0200
     1.3 @@ -258,12 +258,14 @@
     1.4  
     1.5  - (PEP_rating)ratingFromString:(NSString * _Nonnull)string
     1.6  {
     1.7 -    return [PEPSession ratingFromString:string];
     1.8 +    PEPInternalSession *session = [PEPSessionProvider session];
     1.9 +    return [session ratingFromString:string];
    1.10  }
    1.11  
    1.12  - (NSString * _Nonnull)stringFromRating:(PEP_rating)rating
    1.13  {
    1.14 -    return [PEPSession stringFromRating:rating];
    1.15 +    PEPInternalSession *session = [PEPSessionProvider session];
    1.16 +    return [session stringFromRating:rating];
    1.17  }
    1.18  
    1.19  - (BOOL)isPEPUser:(PEPIdentity * _Nonnull)identity
    1.20 @@ -279,18 +281,6 @@
    1.21  
    1.22  #pragma mark Internal API (testing etc.)
    1.23  
    1.24 -+ (PEP_rating)ratingFromString:(NSString * _Nonnull)string
    1.25 -{
    1.26 -    PEPInternalSession *session = [PEPSessionProvider session];
    1.27 -    return [session ratingFromString:string];
    1.28 -}
    1.29 -
    1.30 -+ (NSString * _Nonnull)stringFromRating:(PEP_rating)rating
    1.31 -{
    1.32 -    PEPInternalSession *session = [PEPSessionProvider session];
    1.33 -    return [session stringFromRating:rating];
    1.34 -}
    1.35 -
    1.36  + (BOOL)isPEPUser:(PEPIdentity * _Nonnull)identity;
    1.37  {
    1.38      PEPInternalSession *session = [PEPSessionProvider session];