Made some structs private

This commit is contained in:
bytedream 2022-03-06 02:41:23 +01:00
parent b1e5718c8d
commit a378c93d68

View file

@ -204,7 +204,7 @@ func extractEpisodes(url string, locales ...crunchyroll.LOCALE) [][]*crunchyroll
return final
}
type FormatInformation struct {
type formatInformation struct {
// the format to download
format *crunchyroll.Format
@ -221,7 +221,7 @@ type FormatInformation struct {
Subtitle crunchyroll.LOCALE `json:"subtitle"`
}
func (fi FormatInformation) Format(source string) string {
func (fi formatInformation) Format(source string) string {
fields := reflect.TypeOf(fi)
values := reflect.ValueOf(fi)
@ -246,7 +246,7 @@ func (fi FormatInformation) Format(source string) string {
return source
}
type DownloadProgress struct {
type downloadProgress struct {
Prefix string
Message string
@ -259,15 +259,15 @@ type DownloadProgress struct {
lock sync.Mutex
}
func (dp *DownloadProgress) Update() {
func (dp *downloadProgress) Update() {
dp.update("", false)
}
func (dp *DownloadProgress) UpdateMessage(msg string, permanent bool) {
func (dp *downloadProgress) UpdateMessage(msg string, permanent bool) {
dp.update(msg, permanent)
}
func (dp *DownloadProgress) update(msg string, permanent bool) {
func (dp *downloadProgress) update(msg string, permanent bool) {
if dp.Quiet {
return
}