Rev3158, Fix site clone with sites larger that 10MB
This commit is contained in:
parent
1208294747
commit
74e50e209a
2 changed files with 7 additions and 2 deletions
|
@ -10,7 +10,7 @@ class Config(object):
|
|||
|
||||
def __init__(self, argv):
|
||||
self.version = "0.6.0"
|
||||
self.rev = 3157
|
||||
self.rev = 3158
|
||||
self.argv = argv
|
||||
self.action = None
|
||||
self.config_file = "zeronet.conf"
|
||||
|
|
|
@ -599,11 +599,16 @@ class Site(object):
|
|||
|
||||
# Copy root content.json
|
||||
if not new_site.storage.isFile("content.json") and not overwrite:
|
||||
# Content.json not exist yet, create a new one from source site
|
||||
# New site: Content.json not exist yet, create a new one from source site
|
||||
if "size_limit" in self.settings:
|
||||
new_site.settings["size_limit"] = self.settings["size_limit"]
|
||||
|
||||
# Use content.json-default is specified
|
||||
if self.storage.isFile(root_inner_path + "/content.json-default"):
|
||||
content_json = self.storage.loadJson(root_inner_path + "/content.json-default")
|
||||
else:
|
||||
content_json = self.storage.loadJson("content.json")
|
||||
|
||||
if "domain" in content_json:
|
||||
del content_json["domain"]
|
||||
content_json["title"] = "my" + content_json["title"]
|
||||
|
|
Loading…
Reference in a new issue