mirror of
https://github.com/wassname/FanFicFare.git
synced 2026-09-12 12:02:50 +08:00
Fix for empty word num into int column.
This commit is contained in:
@@ -1469,7 +1469,8 @@ class FanFictionDownLoaderPlugin(InterfaceAction):
|
||||
db.set_custom(book_id, book['all_metadata'][meta], label, commit=False)
|
||||
elif coldef['datatype'] in ('int','float'):
|
||||
num = unicode(book['all_metadata'][meta]).replace(",","")
|
||||
db.set_custom(book_id, num, label=label, commit=False)
|
||||
if num != '':
|
||||
db.set_custom(book_id, num, label=label, commit=False)
|
||||
elif coldef['datatype'] == 'bool' and meta.startswith('status-'):
|
||||
if meta == 'status-C':
|
||||
val = book['all_metadata']['status'] == 'Completed'
|
||||
|
||||
@@ -69,8 +69,9 @@ def removeEntities(text):
|
||||
|
||||
if text is None:
|
||||
return ""
|
||||
if not (isinstance(text,str) or isinstance(text,unicode)):
|
||||
return str(text)
|
||||
|
||||
if not isinstance(text,basestring):
|
||||
return unicode(text)
|
||||
|
||||
try:
|
||||
t = text.decode('utf-8')
|
||||
|
||||
Reference in New Issue
Block a user