Skip to content
This repository was archived by the owner on Dec 18, 2023. It is now read-only.

Commit c854717

Browse files
fix: uploadFile undefined
1 parent 8f22ef0 commit c854717

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@livestorm/cli",
3-
"version": "0.3.3",
3+
"version": "0.3.4",
44
"description": "CLI that allows you to build and deploy your Livestorm plugin",
55
"main": "index.js",
66
"bin": {

src/helpers/uploadFileOrDirectory.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const mediasUrl = `${livestormDomain}/api/v1/medias`
77
let directory = {}
88
let verbose = true
99

10-
module.exports = async function uploadFileOrDirectory(givenPath, isVerbose = true) {
10+
async function uploadFileOrDirectory(givenPath, isVerbose = true) {
1111
verbose = isVerbose
1212
if (fs.lstatSync(givenPath).isDirectory()) {
1313
if (await getDirectoryToken()) uploadDirectory(givenPath)
@@ -16,6 +16,8 @@ module.exports = async function uploadFileOrDirectory(givenPath, isVerbose = tru
1616
}
1717
}
1818

19+
module.exports = uploadFileOrDirectory
20+
1921
async function getDirectoryToken() {
2022
if (directory.token) return directory.token
2123

0 commit comments

Comments
 (0)