Shorten Req.body. функция

const { name, image, description, price, location, user } = req.body;
const author = { id: user._id, username: user._username };
const newCampground = { name, image, description, price, location, author };

// or, without the intermediate `author` variable:

const newCampground = { name, image, description, price, location, author: { id: user._id, username: user._username } };
Stormy Skimmer