aboutsummaryrefslogtreecommitdiff
path: root/mal/episodes.go
diff options
context:
space:
mode:
Diffstat (limited to 'mal/episodes.go')
-rw-r--r--mal/episodes.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/mal/episodes.go b/mal/episodes.go
index 43b69c0..0940af5 100644
--- a/mal/episodes.go
+++ b/mal/episodes.go
@@ -43,3 +43,12 @@ func SetChapters(mangaId, prevValue int, ch string) m.UpdateResponse {
}
return res
}
+
+func SetVolumes(mangaId, prevValue int, vol string) m.UpdateResponse {
+ res, err := userMangaClient.SetVolumesRead(mangaId, util.ParseNumeric(vol, prevValue))
+ if err != nil {
+ fmt.Println("MyAnimeList returned error while updating volumes:", err)
+ os.Exit(1)
+ }
+ return res
+}