Skip to content

Commit

Permalink
1.0.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Symons committed Dec 19, 2013
1 parent a001f32 commit 3a80893
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 6 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
## 1.0.2

* Fix a bug in RKVotable where `voted` would return an incorrect value.
* Add pagination to subscribed subreddits.
* Change RKLink's `URL` property from an NSString to an NSURL.

## 1.0.1

Fix a couple crashes where RKThing subclasses would be created with nil JSON keys.

## 1.0.0

Initial release of RedditKit!
8 changes: 4 additions & 4 deletions Classes/Model/RKVotable.m
Original file line number Diff line number Diff line change
Expand Up @@ -63,21 +63,21 @@ - (BOOL)downvoted

- (BOOL)voted
{
return (self.voteStatus == RKVoteStatusNone);
return (self.voteStatus != RKVoteStatusNone);
}

#pragma mark - MTLModel

+ (NSValueTransformer *)voteStatusJSONTransformer
{
return [MTLValueTransformer transformerWithBlock:^(id forward) {
if (!forward || forward == [NSNull null])
return [MTLValueTransformer transformerWithBlock:^(id vote) {
if (!vote || vote == [NSNull null])
{
return @(RKVoteStatusNone);
}
else
{
BOOL likes = [forward boolValue];
BOOL likes = [vote boolValue];
return likes ? @(RKVoteStatusUpvoted) : @(RKVoteStatusDownvoted);
}
}];
Expand Down
2 changes: 1 addition & 1 deletion Example/Example/Example-Prefix.pch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#import <Availability.h>

#ifdef __OBJC__
#import <UIKit/UIKit.h>
#import <UIKit/UIKit.h>
#import <Foundation/Foundation.h>
#import <RedditKit/RedditKit.h>
#endif
1 change: 0 additions & 1 deletion Example/Example/FrontPageViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
// THE SOFTWARE.

#import "FrontPageViewController.h"
#import <RedditKit/RedditKit.h>
#import "LinkTableViewCell.h"
#import "BrowserViewController.h"
#import "AuthenticationManager.h"
Expand Down

0 comments on commit 3a80893

Please sign in to comment.