Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
antSword
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
HuangJunbo
antSword
Commits
ddd7e66f
Commit
ddd7e66f
authored
Sep 03, 2018
by
Medicean
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix #97 thx @jjf012
parent
4a094464
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
base.js
source/core/base.js
+1
-1
index.js
source/modules/filemanager/index.js
+2
-2
No files found.
source/core/base.js
View file @
ddd7e66f
...
@@ -183,7 +183,7 @@ class Base {
...
@@ -183,7 +183,7 @@ class Base {
parseEncoder
(
enc
)
{
parseEncoder
(
enc
)
{
// 加载编码器
// 加载编码器
// QAQ!我也不知道为什么,如果直接require变量名,babel编译就会warning,so我只好加个`咯~
// QAQ!我也不知道为什么,如果直接require变量名,babel编译就会warning,so我只好加个`咯~
this
[
'__encoder__'
][
enc
.
split
(
`encoder
${
path
.
sep
}
`
)[
1
]]
=
require
(
`
${
enc
}
`
);
this
[
'__encoder__'
][
enc
.
split
(
`encoder
/`
||
`encoder\\
`
)[
1
]]
=
require
(
`
${
enc
}
`
);
}
}
/**
/**
...
...
source/modules/filemanager/index.js
View file @
ddd7e66f
...
@@ -637,7 +637,7 @@ class FileManager {
...
@@ -637,7 +637,7 @@ class FileManager {
}).
then
((
filePaths
)
=>
{
}).
then
((
filePaths
)
=>
{
// 初始化任务
// 初始化任务
filePaths
.
map
((
f
)
=>
{
filePaths
.
map
((
f
)
=>
{
const
fileName
=
f
.
substr
(
f
.
lastIndexOf
(
'/'
)
+
1
);
const
fileName
=
f
.
substr
(
f
.
lastIndexOf
(
PATH
.
sep
)
+
1
);
tasks
[
f
]
=
this
.
tasks
.
new
(
LANG
[
'upload'
][
'task'
][
'name'
],
`
${
fileName
}
=>
${
path
}
`
,
'Waiting for uploading..'
);
tasks
[
f
]
=
this
.
tasks
.
new
(
LANG
[
'upload'
][
'task'
][
'name'
],
`
${
fileName
}
=>
${
path
}
`
,
'Waiting for uploading..'
);
});
});
return
filePaths
;
return
filePaths
;
...
@@ -661,7 +661,7 @@ class FileManager {
...
@@ -661,7 +661,7 @@ class FileManager {
}
}
let
task
=
tasks
[
filePath
];
let
task
=
tasks
[
filePath
];
// 获取文件名
// 获取文件名
let
fileName
=
filePath
.
substr
(
filePath
.
lastIndexOf
(
'/'
)
+
1
);
let
fileName
=
filePath
.
substr
(
filePath
.
lastIndexOf
(
PATH
.
sep
)
+
1
);
// 读取文件buff
// 读取文件buff
let
fileBuff
;
let
fileBuff
;
try
{
try
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment