Support for Local Novels. Adjusted Metadata File Finding to not rely on File order.

This commit is contained in:
Neshura 2025-03-02 00:24:36 +01:00
parent 741eed00ac
commit 589f5dc141
Signed by: Neshura
GPG key ID: 4E2D47B1374C297D
2 changed files with 308 additions and 162 deletions

View file

@ -125,6 +125,14 @@ func (creators Creators) Get(role string) *Creator {
return &(creators)[idx]
}
func (creators Creators) TryGetName(role string) string {
if creators.Contains(role) {
return creators.Get(role).Name
} else {
return ""
}
}
type VolumeAugmented struct {
Info Volume
Downloads []Download
@ -199,6 +207,15 @@ type Pagination struct {
LastPage bool `json:"lastPage"`
}
type ProviderSettings struct {
Domain string
Series string
Directory string
Username string
Password string
Language string
}
func NewJNC(domain string) Api {
baseUrl := fmt.Sprintf("https://%s/", domain)
jncApi := Api{