@cocreate/file-server 1.0.7 → 1.0.9
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/CHANGELOG.md +15 -0
- package/package.json +3 -3
- package/src/index.js +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
## [1.0.9](https://github.com/CoCreate-app/CoCreate-file-server/compare/v1.0.8...v1.0.9) (2022-12-05)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* send html and organization_id to render.HTML ([a11390b](https://github.com/CoCreate-app/CoCreate-file-server/commit/a11390be2c40cdead9eaeab253c11477cafe21f7))
|
|
7
|
+
|
|
8
|
+
## [1.0.8](https://github.com/CoCreate-app/CoCreate-file-server/compare/v1.0.7...v1.0.8) (2022-12-04)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* || !organization.document ([d462728](https://github.com/CoCreate-app/CoCreate-file-server/commit/d462728e319d6af3d87487f75b2b12ef6a495255))
|
|
14
|
+
* bump dependencies ([9c53845](https://github.com/CoCreate-app/CoCreate-file-server/commit/9c5384510a632fa53a7e569779cfdef2ef51aef2))
|
|
15
|
+
|
|
1
16
|
## [1.0.7](https://github.com/CoCreate-app/CoCreate-file-server/compare/v1.0.6...v1.0.7) (2022-12-04)
|
|
2
17
|
|
|
3
18
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cocreate/file-server",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.9",
|
|
4
4
|
"description": "A simple file-server component in vanilla javascript. Easily configured using HTML5 data-attributes and/or JavaScript API.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"file-server",
|
|
@@ -61,8 +61,8 @@
|
|
|
61
61
|
"webpack-log": "^3.0.1"
|
|
62
62
|
},
|
|
63
63
|
"dependencies": {
|
|
64
|
-
"@cocreate/docs": "^1.
|
|
65
|
-
"@cocreate/hosting": "^1.
|
|
64
|
+
"@cocreate/docs": "^1.4.13",
|
|
65
|
+
"@cocreate/hosting": "^1.6.11",
|
|
66
66
|
"@cocreate/server-side-render": "^1.1.20",
|
|
67
67
|
"express": "^4.18.2"
|
|
68
68
|
}
|
package/src/index.js
CHANGED
|
@@ -31,7 +31,7 @@ class CoCreateFileSystem {
|
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
})
|
|
34
|
-
if (!organization || !organization.document[0])
|
|
34
|
+
if (!organization || !organization.document || !organization.document[0])
|
|
35
35
|
return res.send('Organization cannot be found using the domain: ' + hostname + ' in platformDB: ' + masterOrg);
|
|
36
36
|
|
|
37
37
|
organization_id = organization.document[0]._id
|
|
@@ -100,7 +100,7 @@ class CoCreateFileSystem {
|
|
|
100
100
|
}
|
|
101
101
|
else if (content_type === 'text/html') {
|
|
102
102
|
try {
|
|
103
|
-
let fullHtml = await render.
|
|
103
|
+
let fullHtml = await render.HTML(src, organization_id);
|
|
104
104
|
res.type(content_type);
|
|
105
105
|
res.send(fullHtml);
|
|
106
106
|
}
|