Skip to content

Commit

Permalink
3.1.8 - Fix title confirmation
Browse files Browse the repository at this point in the history
  • Loading branch information
香風智乃 authored and 香風智乃 committed May 3, 2019
1 parent f04d24b commit 86693ce
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Hachidori-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>3.1.7</string>
<string>3.1.8</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>20190422</string>
<string>20190504</string>
<key>LSApplicationCategoryType</key>
<string>public.app-category.entertainment</string>
<key>LSMinimumSystemVersion</key>
Expand Down
5 changes: 4 additions & 1 deletion Hachidori.m
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,10 @@ - (BOOL)confirmupdate {
NSLog(@"=============");
NSLog(@"Confirming: %@ - %@",self.lastscrobble.LastScrobbledActualTitle, self.lastscrobble.LastScrobbledEpisode);
[MSAnalytics trackEvent:@"Confirming title." withProperties:@{@"detectedTitle" : self.lastscrobble.LastScrobbledTitle, @"actualtitle" : self.lastscrobble.LastScrobbledActualTitle, @"season" : @(self.lastscrobble.DetectedSeason).stringValue, @"source":self.lastscrobble.LastScrobbledSource, @"episode" : self.lastscrobble.LastScrobbledEpisode, @"service" : [Hachidori currentServiceName]}];
int status = [self performupdate:self.detectedscrobble.AniID withService:(int)[Hachidori currentService]];
DetectedScrobbleStatus *tmpdetected = [DetectedScrobbleStatus new];
[tmpdetected transferLastScrobbled:[self getLastScrobbleForService:[Hachidori currentService]]];
[self setDetectedScrobbleStatus:tmpdetected withService:[Hachidori currentService]];
int status = [self performupdate:self.lastscrobble.AniID withService:(int)[Hachidori currentService]];
switch (status) {
case ScrobblerAddTitleSuccessful:
case ScrobblerUpdateSuccessful:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Hachidori.m"
timestampString = "577033605.845787"
timestampString = "578605275.987215"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "986"
endingLineNumber = "986"
startingLineNumber = "989"
endingLineNumber = "989"
landmarkName = "-checkType"
landmarkType = "7">
</BreakpointContent>
Expand Down
3 changes: 2 additions & 1 deletion ScrobbleObjects/DetectedScrobbleStatus.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

#import <Foundation/Foundation.h>
#import "Scrobble.h"

@class LastScrobbleStatus;
@interface DetectedScrobbleStatus : Scrobble <NSCopying>
@property (strong) NSString *DetectedTitle;
@property (strong) NSString *DetectedEpisode;
Expand All @@ -19,5 +19,6 @@
@property (strong) NSString *FailedSource;
@property (getter=getFailedSeason) int FailedSeason;
- (void)checkzeroEpisode;
- (void)transferLastScrobbled:(LastScrobbleStatus *)lscrobbled;
@end

27 changes: 27 additions & 0 deletions ScrobbleObjects/DetectedScrobbleStatus.m
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
//

#import "DetectedScrobbleStatus.h"
#import "LastScrobbleStatus.h"

@implementation DetectedScrobbleStatus
- (void)checkzeroEpisode {
Expand Down Expand Up @@ -36,4 +37,30 @@ - (id)copyWithZone:(NSZone *)zone {
detectedscrobblecopy.DetectedTitleisEpisodeZero = self.DetectedTitleisEpisodeZero;
return detectedscrobblecopy;
}

- (void)transferLastScrobbled:(LastScrobbleStatus *)lscrobbled {
self.DetectedTitle = lscrobbled.LastScrobbledTitle;
self.DetectedEpisode = lscrobbled.LastScrobbledEpisode;
self.DetectedSource = lscrobbled.LastScrobbledSource;
self.DetectedCurrentEpisode = lscrobbled.DetectedCurrentEpisode;
self.LastScrobbledInfo = lscrobbled.LastScrobbledInfo;
self.LastScrobbledTitleNew = lscrobbled.LastScrobbledTitleNew;
self.isPrivate = lscrobbled.isPrivate;
self.startDate = lscrobbled.startDate;
self.endDate = lscrobbled.endDate;
self.airing = lscrobbled.airing;
self.completedairing = lscrobbled.completedairing;
self.TotalEpisodes = lscrobbled.TotalEpisodes;
self.DetectedTitleisMovie = lscrobbled.DetectedTitleisMovie;
self.DetectedTitleisEpisodeZero = lscrobbled.DetectedTitleisEpisodeZero;
self.WatchStatus = lscrobbled.WatchStatus;
self.TitleScore = lscrobbled.TitleScore;
self.rewatchcount = lscrobbled.rewatchcount;
self.rewatching = lscrobbled.rewatching;
self.TitleNotes = lscrobbled.TitleNotes;
self.AniID = lscrobbled.AniID;
self.EntryID = lscrobbled.EntryID;
self.slug = lscrobbled.slug;
self.confirmed = lscrobbled.confirmed;
}
@end

0 comments on commit 86693ce

Please sign in to comment.