Skip to content

Commit

Permalink
Fix uploading to DO
Browse files Browse the repository at this point in the history
  • Loading branch information
foyzulkarim committed Oct 8, 2023
1 parent 0a3ba29 commit b940f07
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions server/src/modules/models/video/controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -179,14 +179,14 @@ const setupRoutes = (app) => {

const dbPayload = {
...req.body,
fileName: req.file.filename,
fileName: req.file.originalname,
originalName: req.file.originalname,
recordingDate: new Date(),
videoLink: req.file.path,
videoLink: req.file.location,
viewCount: 0,
duration: 0,
};
logger.info('dbPayload', dbPayload);
logger.info('dbPayload', { dbPayload });
// TODO: save the file info and get the id from the database
const result = await insert(dbPayload);
logger.info('result', result);
Expand Down

0 comments on commit b940f07

Please sign in to comment.