]> git.lizzy.rs Git - go-anidb.git/commitdiff
misc: Rename (Episode).(Inc|Dec) to (Episode).(IncPart|DecPart)
authorDiogo Franco (Kovensky) <diogomfranco@gmail.com>
Wed, 17 Jul 2013 20:53:31 +0000 (17:53 -0300)
committerDiogo Franco (Kovensky) <diogomfranco@gmail.com>
Wed, 17 Jul 2013 20:53:31 +0000 (17:53 -0300)
misc/episode.go
misc/episoderange.go

index 1dbd1726e899236efb37bea898ad6389d8a7a9dd..c5d41a88e3e566beaebbd9a8285947f08b64c596 100644 (file)
@@ -134,7 +134,7 @@ func (ep *Episode) FormatLog(max int) string {
        return ep.Format(scale(max))
 }
 
-func (ep *Episode) Inc() {
+func (ep *Episode) IncPart() {
        if ep.Parts > 0 && ep.Part == ep.Parts-1 {
                ep.IncNumber()
        } else {
@@ -148,7 +148,7 @@ func (ep *Episode) IncNumber() {
        ep.Number++
 }
 
-func (ep *Episode) Dec() {
+func (ep *Episode) DecPart() {
        if ep.Part > 0 {
                ep.Part--
        } else {
index 8f679b10440b76df8bccedc8f89816fb1d84b561..7e750cc7328e984f438749ad8f124ab116c77fb0 100644 (file)
@@ -217,7 +217,7 @@ func (er *EpisodeRange) Split(ep *Episode) []*EpisodeRange {
                return []*EpisodeRange{nil, nil}
        case a.ContainsEpisodes(ep):
                if ep.Part >= 0 {
-                       a.Inc()
+                       a.IncPart()
                } else {
                        a.IncNumber()
                }
@@ -233,7 +233,7 @@ func (er *EpisodeRange) Split(ep *Episode) []*EpisodeRange {
                return []*EpisodeRange{nil, r.Simplify()}
        case b.ContainsEpisodes(ep):
                if ep.Part >= 0 {
-                       b.Dec()
+                       b.DecPart()
                } else {
                        b.DecNumber()
                }