adding aws upload to the create post api
This commit is contained in:
@@ -9,6 +9,7 @@ import { fileURLToPath } from 'url';
|
||||
import xss from 'xss-clean';
|
||||
|
||||
import indexRouter from './routes/index.js';
|
||||
import postsRouter from './routes/posts.js';
|
||||
import usersRouter from './routes/users.js';
|
||||
|
||||
const __filename = fileURLToPath(import.meta.url);
|
||||
@@ -33,7 +34,7 @@ app.use(xss());
|
||||
|
||||
app.use('/', indexRouter);
|
||||
app.use('/api/v1/users', usersRouter);
|
||||
// app.use('/api/v1/posts', usersRouter);
|
||||
app.use('/api/v1/posts', postsRouter);
|
||||
|
||||
// catch 404 and forward to error handler
|
||||
app.use(function(req, res, next) {
|
||||
|
||||
Reference in New Issue
Block a user