File tree Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -303,14 +303,6 @@ def add_item_for(
303
303
if should_compress is not None :
304
304
hints [libzim .writer .Hint .COMPRESS ] = should_compress
305
305
306
- kwargs = {
307
- "path" : path ,
308
- "title" : title or "" ,
309
- "mimetype" : mimetype ,
310
- "filepath" : fpath if fpath is not None else "" ,
311
- "hints" : hints ,
312
- "content" : content ,
313
- }
314
306
if delete_fpath and fpath :
315
307
cb = [delete_callback , fpath ]
316
308
if callback and callable (callback ):
@@ -320,7 +312,16 @@ def add_item_for(
320
312
callback = tuple (cb )
321
313
322
314
self .add_item (
323
- StaticItem (** kwargs ), callback = callback , duplicate_ok = duplicate_ok
315
+ StaticItem (
316
+ path = path ,
317
+ title = title ,
318
+ mimetype = mimetype ,
319
+ filepath = fpath ,
320
+ hints = hints ,
321
+ content = content ,
322
+ ),
323
+ callback = callback ,
324
+ duplicate_ok = duplicate_ok ,
324
325
)
325
326
return path
326
327
You can’t perform that action at this time.
0 commit comments