perf(architecture): Big performance improvements over big databases and files highlight in search. (#63)

Reduction database space over 50%. Change database version to v7.

BREAKING CHANGE: databases v6 and v7 are incompatible and need a lot of time for updating (may be even some days/a lot of hours on very big databases)
This commit is contained in:
Alexey Kasyanchuk
2018-11-11 23:44:10 +03:00
committed by GitHub
parent 13ca63b954
commit 6afe85798a
11 changed files with 271 additions and 111 deletions

View File

@ -0,0 +1,12 @@
module.exports = (filesData) => {
if(Array.isArray(filesData))
filesData = filesData[0]
let path = filesData.path.split('\n');
let size = filesData.size.split('\n');
return path.map((pathString, index) => Object.assign({}, filesData, {
path: pathString,
size: parseInt(size[index])
}))
}