From 0521895f11e9cbafe49585f1fe65f637f888036c Mon Sep 17 00:00:00 2001 From: bytedream Date: Thu, 23 Jun 2022 16:59:54 +0200 Subject: [PATCH] Add function to check if comment is flagged as spoiler --- comment.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/comment.go b/comment.go index 98c400c..dc68201 100644 --- a/comment.go +++ b/comment.go @@ -233,6 +233,10 @@ func (c *Comment) FlagAsSpoiler() error { return c.vote("spoiler", "spoiler") } +func (c *Comment) IsFlaggedAsSpoiler() bool { + return c.markedAs("spoiler") +} + // UnflagAsSpoiler rewokes the request to the user (and / or crunchyroll?) to mark the // comment as spoiler. Only works if the user has flagged the comment as spoiler. func (c *Comment) UnflagAsSpoiler() error {