Fix some events
This commit is contained in:
parent
39e7fe5d69
commit
2a3271ef4e
|
@ -34,14 +34,18 @@ module.exports = function systemEventUserLogInit(statLog) {
|
||||||
append(e, LogNames.Logoff, e.minutesOnline);
|
append(e, LogNames.Logoff, e.minutesOnline);
|
||||||
},
|
},
|
||||||
[ systemEvents.UserUpload ] : (e) => {
|
[ systemEvents.UserUpload ] : (e) => {
|
||||||
append(e, LogNames.UlFiles, e.files.length);
|
if(e.files.length) { // we can get here for dupe uploads
|
||||||
const totalBytes = e.files.reduce( (bytes, fileEntry) => bytes + fileEntry.meta.byte_size, 0);
|
append(e, LogNames.UlFiles, e.files.length);
|
||||||
append(e, LogNames.UlFileBytes, totalBytes);
|
const totalBytes = e.files.reduce( (bytes, fileEntry) => bytes + fileEntry.meta.byte_size, 0);
|
||||||
|
append(e, LogNames.UlFileBytes, totalBytes);
|
||||||
|
}
|
||||||
},
|
},
|
||||||
[ systemEvents.UserDownload ] : (e) => {
|
[ systemEvents.UserDownload ] : (e) => {
|
||||||
append(e, LogNames.DlFiles, e.files.length);
|
if(e.files.length) {
|
||||||
const totalBytes = e.files.reduce( (bytes, fileEntry) => bytes + fileEntry.meta.byte_size, 0);
|
append(e, LogNames.DlFiles, e.files.length);
|
||||||
append(e, LogNames.DlFileBytes, totalBytes);
|
const totalBytes = e.files.reduce( (bytes, fileEntry) => bytes + fileEntry.byteSize, 0);
|
||||||
|
append(e, LogNames.DlFileBytes, totalBytes);
|
||||||
|
}
|
||||||
},
|
},
|
||||||
[ systemEvents.UserPostMessage ] : (e) => {
|
[ systemEvents.UserPostMessage ] : (e) => {
|
||||||
append(e, LogNames.PostMessage, e.areaTag);
|
append(e, LogNames.PostMessage, e.areaTag);
|
||||||
|
|
Loading…
Reference in New Issue