fix: ensure correct file path when importing package
This commit is contained in:
parent
8daf25bec6
commit
d9167985b1
1 changed files with 2 additions and 1 deletions
|
|
@ -10,6 +10,7 @@ from frappe.desk.form.load import get_attachments
|
|||
from frappe.model.document import Document
|
||||
from frappe.model.sync import get_doc_files
|
||||
from frappe.modules.import_file import import_doc, import_file_by_path
|
||||
from frappe.utils import get_files_path
|
||||
|
||||
|
||||
class PackageImport(Document):
|
||||
|
|
@ -35,7 +36,7 @@ class PackageImport(Document):
|
|||
[
|
||||
"tar",
|
||||
"xzf",
|
||||
frappe.get_site_path(attachment.file_url.strip("/")),
|
||||
get_files_path(attachment.file_name, is_private=attachment.is_private),
|
||||
"-C",
|
||||
frappe.get_site_path("packages"),
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue