From 07caaa6b481fcc0276f5cb9cb1855d88a28af399 Mon Sep 17 00:00:00 2001 From: shortcutme Date: Thu, 5 Oct 2017 19:24:39 +0200 Subject: [PATCH] Fix removed is_pinned flag on content.json update --- plugins/OptionalManager/ContentDbPlugin.py | 6 +++--- src/Config.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/plugins/OptionalManager/ContentDbPlugin.py b/plugins/OptionalManager/ContentDbPlugin.py index 5d7942e8..961a7390 100644 --- a/plugins/OptionalManager/ContentDbPlugin.py +++ b/plugins/OptionalManager/ContentDbPlugin.py @@ -179,8 +179,7 @@ class ContentDbPlugin(object): is_pinned = 0 cur.insertOrUpdate("file_optional", { "hash_id": hash_id, - "size": int(file["size"]), - "is_pinned": is_pinned + "size": int(file["size"]) }, { "site_id": site_id, "inner_path": file_inner_path @@ -188,7 +187,8 @@ class ContentDbPlugin(object): "time_added": int(time.time()), "time_downloaded": int(time.time()) if is_downloaded else 0, "is_downloaded": is_downloaded, - "peer": is_downloaded + "peer": is_downloaded, + "is_pinned": is_pinned }) self.optional_files[site_id][file_inner_path[-8:]] = 1 num += 1 diff --git a/src/Config.py b/src/Config.py index ea0d2d41..a9d016bf 100644 --- a/src/Config.py +++ b/src/Config.py @@ -10,7 +10,7 @@ class Config(object): def __init__(self, argv): self.version = "0.6.0" - self.rev = 3094 + self.rev = 3095 self.argv = argv self.action = None self.config_file = "zeronet.conf"