mirror of
https://github.com/crunchy-labs/crunchy-cli.git
synced 2026-01-21 12:12:00 -06:00
Fix typos & add more comments
This commit is contained in:
parent
2e9ce3cf52
commit
3617955bc5
16 changed files with 82 additions and 68 deletions
|
|
@ -11,11 +11,12 @@ const (
|
|||
MOVIE = "movies"
|
||||
)
|
||||
|
||||
// Format contains detailed information about an episode video stream.
|
||||
type Format struct {
|
||||
crunchy *Crunchyroll
|
||||
|
||||
ID string
|
||||
// FormatType represents if the format parent is an episode or a movie
|
||||
// FormatType represents if the format parent is an episode or a movie.
|
||||
FormatType FormatType
|
||||
Video *m3u8.Variant
|
||||
AudioLocale LOCALE
|
||||
|
|
@ -27,7 +28,7 @@ type Format struct {
|
|||
// The Format.Video.Chunklist pointer is, by default, nil because an additional
|
||||
// request must be made to receive its content. The request is not made when
|
||||
// initializing a Format struct because it would probably cause an intense overhead
|
||||
// since Format.Video.Chunklist is only used sometimes
|
||||
// since Format.Video.Chunklist is only used sometimes.
|
||||
func (f *Format) InitVideo() error {
|
||||
if f.Video.Chunklist == nil {
|
||||
resp, err := f.crunchy.Client.Get(f.Video.URI)
|
||||
|
|
@ -45,7 +46,7 @@ func (f *Format) InitVideo() error {
|
|||
return nil
|
||||
}
|
||||
|
||||
// Download downloads the Format with the via Downloader specified options
|
||||
// Download downloads the Format with the via Downloader specified options.
|
||||
func (f *Format) Download(downloader Downloader) error {
|
||||
return downloader.download(f)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue