lrf402788946 3 years ago
parent
commit
05555da487
1 changed files with 1 additions and 1 deletions
  1. 1 1
      app/controller/files.js

+ 1 - 1
app/controller/files.js

@@ -180,7 +180,7 @@ class FilesController extends Controller {
     }
 
     let returnUri = `${filePath}/${fileName}`;
-    while (returnUri.indexOf('//')) {
+    while (returnUri.indexOf('//') >= 0) {
       returnUri = returnUri.replace('//', '/');
     }
     this.ctx.body = this.getSuccessReturn({ uri: returnUri, id: fileName });