Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
douban-api-proxy
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
captainwong
douban-api-proxy
Commits
013793f9
Commit
013793f9
authored
May 17, 2020
by
Ozzieisaacs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix for #1391 (Kobo sync not working if series is given, but no series_index)
parent
2468cf63
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
+5
-2
kobo.py
cps/kobo.py
+5
-2
No files found.
cps/kobo.py
View file @
013793f9
...
...
@@ -332,6 +332,9 @@ def get_series(book):
return
None
return
book
.
series
[
0
]
.
name
def
get_seriesindex
(
book
):
return
book
.
series_index
or
1
def
get_metadata
(
book
):
download_urls
=
[]
...
...
@@ -386,8 +389,8 @@ def get_metadata(book):
name
=
get_series
(
book
)
metadata
[
"Series"
]
=
{
"Name"
:
get_series
(
book
),
"Number"
:
book
.
series_index
,
# ToDo Check int() ?
"NumberFloat"
:
float
(
book
.
series_index
),
"Number"
:
get_seriesindex
(
book
)
,
# ToDo Check int() ?
"NumberFloat"
:
float
(
get_seriesindex
(
book
)
),
# Get a deterministic id based on the series name.
"Id"
:
uuid
.
uuid3
(
uuid
.
NAMESPACE_DNS
,
name
),
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment