Friendship Accepted and Refused (notification updated)
This commit is contained in:
@@ -1063,6 +1063,7 @@ router.get('/loadsite/:userId/:idapp/:vers', authenticate_noerror,
|
||||
let version = tools.getVersionint(versionstr);
|
||||
|
||||
load(req, res, version);
|
||||
|
||||
});
|
||||
|
||||
function load(req, res, version) {
|
||||
@@ -1496,9 +1497,10 @@ function uploadFile(req, res, version) {
|
||||
sharp(newname, {failOnError: false}).
|
||||
resize({
|
||||
width: 512,
|
||||
height: 512,
|
||||
fit: sharp.fit.cover,
|
||||
position: sharp.strategy.entropy,
|
||||
// height: 512,
|
||||
//fit: sharp.fit.cover,
|
||||
fit: sharp.fit.contain,
|
||||
// position: sharp.strategy.entropy,
|
||||
}).withMetadata().toFile(resized_img, function(err) {
|
||||
|
||||
// console.log('3) Ridimensionata Immagine ' + newname, 'in', resized_img);
|
||||
|
||||
@@ -26,7 +26,7 @@ const isValidSaveRequest = (req, res) => {
|
||||
}
|
||||
};
|
||||
|
||||
router.post('/', authenticate, (req, res) => {
|
||||
router.post('/', authenticate, async (req, res) => {
|
||||
// console.log('req.body.others', req.body.others);
|
||||
|
||||
if (!isValidSaveRequest(req, res)) {
|
||||
@@ -39,7 +39,7 @@ router.post('/', authenticate, (req, res) => {
|
||||
subscriptionModel.browser = req.get('User-Agent');
|
||||
|
||||
// Find if already exist
|
||||
Subscription.findOne({
|
||||
await Subscription.findOne({
|
||||
userId: subscriptionModel.userId,
|
||||
access: subscriptionModel.access,
|
||||
browser: subscriptionModel.browser,
|
||||
|
||||
Reference in New Issue
Block a user