about summary refs log tree commit diff
diff options
context:
space:
mode:
authorPaweł Jastrzębski <pawelj@iosphe.re>2019-08-04 09:29:03 +0200
committerPaweł Jastrzębski <pawelj@iosphe.re>2019-08-04 09:29:03 +0200
commit5f5157c1d40dfb1c8ecc33e026f3d4ef9b01c34a (patch)
tree37ad7aa30573cb72c3151d43216425e2d3ced2b9
parentFixed handling filenames that start with dot (close #310) (diff)
downloadkcc-5f5157c1d40dfb1c8ecc33e026f3d4ef9b01c34a.tar.gz
kcc-5f5157c1d40dfb1c8ecc33e026f3d4ef9b01c34a.tar.bz2
kcc-5f5157c1d40dfb1c8ecc33e026f3d4ef9b01c34a.zip
No longer modify header field 504
-rw-r--r--kindlecomicconverter/dualmetafix.py8
1 files changed, 2 insertions, 6 deletions
diff --git a/kindlecomicconverter/dualmetafix.py b/kindlecomicconverter/dualmetafix.py
index c05dc85..7426f93 100644
--- a/kindlecomicconverter/dualmetafix.py
+++ b/kindlecomicconverter/dualmetafix.py
@@ -143,14 +143,12 @@ class DualMobiMetaFix:
         self.datain_rec0 = readsection(self.datain, 0)
 
         # in the first mobi header
-        # add 501 to "EBOK", add 113 as asin, add 504 as asin
+        # add 501 to "EBOK", add 113 as asin
         rec0 = self.datain_rec0
         rec0 = del_exth(rec0, 501)
         rec0 = del_exth(rec0, 113)
-        rec0 = del_exth(rec0, 504)
         rec0 = add_exth(rec0, 501, b'EBOK')
         rec0 = add_exth(rec0, 113, asin)
-        rec0 = add_exth(rec0, 504, asin)
         replacesection(self.datain, 0, rec0)
 
         ver = getint(self.datain_rec0, mobi_version)
@@ -172,14 +170,12 @@ class DualMobiMetaFix:
         self.datain_kfrec0 = readsection(self.datain, datain_kf8)
 
         # in the second header
-        # add 501 to "EBOK", add 113 as asin, add 504 as asin
+        # add 501 to "EBOK", add 113 as asin
         rec0 = self.datain_kfrec0
         rec0 = del_exth(rec0, 501)
         rec0 = del_exth(rec0, 113)
-        rec0 = del_exth(rec0, 504)
         rec0 = add_exth(rec0, 501, b'EBOK')
         rec0 = add_exth(rec0, 113, asin)
-        rec0 = add_exth(rec0, 504, asin)
         replacesection(self.datain, datain_kf8, rec0)
 
         self.datain.flush()