mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-10-31 02:55:58 +01:00 
			
		
		
		
	fix: doggy.gif
This commit is contained in:
		| @@ -3,7 +3,6 @@ | ||||
| 'use strict'; | ||||
|  | ||||
| const crypto = require('crypto'); | ||||
| const _ = require('lodash'); | ||||
|  | ||||
| const db = require('../../database'); | ||||
| const batch = require('../../batch'); | ||||
| @@ -28,7 +27,7 @@ module.exports = { | ||||
| 				let uploads = await db.getSortedSetRangeWithScores(key, 0, -1); | ||||
|  | ||||
| 				// Don't process those that have already the right format | ||||
| 				uploads = _.uniq(uploads.filter(upload => !upload.value.startsWith('files/'))); | ||||
| 				uploads = uploads.filter(upload => upload && upload.value && !upload.value.startsWith('files/')); | ||||
|  | ||||
| 				// Rename the zset members | ||||
| 				await db.sortedSetRemove(key, uploads.map(upload => upload.value)); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user