verteilen-core 1.3.33 → 1.3.35
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/server/plugin.js +3 -3
- package/package.json +1 -1
- package/src/server/plugin.ts +3 -3
package/dist/server/plugin.js
CHANGED
|
@@ -10,7 +10,7 @@ const GetCurrentPlugin = async (loader) => {
|
|
|
10
10
|
if (!loader.exists(root))
|
|
11
11
|
await loader.mkdir(root);
|
|
12
12
|
const plugin_folder = await loader.read_dir_dir(root);
|
|
13
|
-
const plugin_folder_files = await Promise.all(plugin_folder.map(x => loader.read_dir_file(x)));
|
|
13
|
+
const plugin_folder_files = await Promise.all(plugin_folder.map(x => loader.read_dir_file(loader.join(root, x))));
|
|
14
14
|
for (let i = 0; i < plugin_folder_files.length; i++) {
|
|
15
15
|
const files = plugin_folder_files[i];
|
|
16
16
|
const dirname = plugin_folder[i];
|
|
@@ -123,8 +123,8 @@ const CreatePluginLoader = (loader, memory, socket, feedback) => {
|
|
|
123
123
|
ob.url = url;
|
|
124
124
|
loader.write_string(loader.join(root, name, 'manifest.json'), JSON.stringify(ob, null, 4));
|
|
125
125
|
const folder = url.substring(0, url.lastIndexOf('/'));
|
|
126
|
-
const project_calls = ob.projects.map(p => fetch(folder + "/" + p.filename + '.json', req));
|
|
127
|
-
const database_calls = ob.databases.map(p => fetch(folder + "/" + p.filename + '.json', req));
|
|
126
|
+
const project_calls = ob.projects.map(p => fetch(folder + "/project/" + p.filename + '.json', req));
|
|
127
|
+
const database_calls = ob.databases.map(p => fetch(folder + "/database/" + p.filename + '.json', req));
|
|
128
128
|
const pss = await Promise.all(project_calls);
|
|
129
129
|
const project_calls2 = pss.map(x => x.text());
|
|
130
130
|
const pss_result = await Promise.all(project_calls2);
|
package/package.json
CHANGED
package/src/server/plugin.ts
CHANGED
|
@@ -90,7 +90,7 @@ export const GetCurrentPlugin = async (loader:RecordIOBase):Promise<PluginPageDa
|
|
|
90
90
|
if(!loader.exists(root)) await loader.mkdir(root)
|
|
91
91
|
|
|
92
92
|
const plugin_folder = await loader.read_dir_dir(root)
|
|
93
|
-
const plugin_folder_files = await Promise.all(plugin_folder.map(x => loader.read_dir_file(x)))
|
|
93
|
+
const plugin_folder_files = await Promise.all(plugin_folder.map(x => loader.read_dir_file(loader.join(root, x))))
|
|
94
94
|
for(let i = 0; i < plugin_folder_files.length; i++){
|
|
95
95
|
const files = plugin_folder_files[i]
|
|
96
96
|
const dirname = plugin_folder[i]
|
|
@@ -200,8 +200,8 @@ export const CreatePluginLoader = (loader:RecordIOBase, memory:PluginPageData, s
|
|
|
200
200
|
loader.write_string(loader.join(root, name, 'manifest.json'), JSON.stringify(ob, null, 4))
|
|
201
201
|
|
|
202
202
|
const folder = url.substring(0, url.lastIndexOf('/'))
|
|
203
|
-
const project_calls:Array<Promise<Response>> = ob.projects.map(p => fetch(folder + "/" + p.filename + '.json', req))
|
|
204
|
-
const database_calls:Array<Promise<Response>> = ob.databases.map(p => fetch(folder + "/" + p.filename + '.json', req))
|
|
203
|
+
const project_calls:Array<Promise<Response>> = ob.projects.map(p => fetch(folder + "/project/" + p.filename + '.json', req))
|
|
204
|
+
const database_calls:Array<Promise<Response>> = ob.databases.map(p => fetch(folder + "/database/" + p.filename + '.json', req))
|
|
205
205
|
// * Project template query
|
|
206
206
|
const pss = await Promise.all(project_calls)
|
|
207
207
|
const project_calls2:Array<Promise<string>> = pss.map(x => x.text())
|