mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-02-02 04:40:01 +01:00
Merge branch 'master' into develop
This commit is contained in:
@@ -208,9 +208,6 @@ module.exports = function (User) {
|
||||
|
||||
async function deleteImages(uid) {
|
||||
const folder = path.join(nconf.get('upload_path'), 'profile');
|
||||
await Promise.all([
|
||||
rimraf(path.join(folder, `${uid}-profilecover*`), { glob: true }),
|
||||
rimraf(path.join(folder, `${uid}-profileavatar*`), { glob: true }),
|
||||
]);
|
||||
await rimraf(`${uid}-profile{avatar,cover}*`, { glob: { cwd: folder } });
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user