Skip to content

Commit

Permalink
Fixed app_context in link received from inline file upload
Browse files Browse the repository at this point in the history
  • Loading branch information
Mark Moffat committed Mar 14, 2017
1 parent 382ba55 commit c4733e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion routes/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -1111,7 +1111,7 @@ router.post('/file/upload_file', common.restrict, inline_upload.single('file'),
if(req.file){
// check for upload select
var upload_dir = path.join(appDir, 'public', 'uploads', 'inline_files');
var relative_upload_dir = '/uploads/inline_files';
var relative_upload_dir = req.app_context + '/uploads/inline_files';

var file = req.file;
var source = fs.createReadStream(file.path);
Expand Down

0 comments on commit c4733e9

Please sign in to comment.