Add linting and unused cleanup

This commit is contained in:
Alf Hammerseth
2019-11-16 15:16:34 +01:00
parent ce7ac96a5d
commit 120553eac4
12 changed files with 1560 additions and 1066 deletions

View File

@@ -10,12 +10,24 @@ var toShowConfig = {
startTime: 1,
userpass: 1,
vote: 1,
toggleChat: { $ifNull: ["$toggleChat", true] },
strictSkip: { $ifNull: ["$strictSkip", false] },
strictSkipNumber: { $ifNull: ["$strictSkipNumber", 10] },
description: { $ifNull: ["$description", ""] },
thumbnail: { $ifNull: ["$thumbnail", ""] },
rules: { $ifNull: ["$rules", ""] },
toggleChat: {
$ifNull: ["$toggleChat", true]
},
strictSkip: {
$ifNull: ["$strictSkip", false]
},
strictSkipNumber: {
$ifNull: ["$strictSkipNumber", 10]
},
description: {
$ifNull: ["$description", ""]
},
thumbnail: {
$ifNull: ["$thumbnail", ""]
},
rules: {
$ifNull: ["$rules", ""]
},
_id: 0
};
@@ -30,8 +42,12 @@ var project_object = {
duration: 1,
end: 1,
type: 1,
added_by: { $ifNull: ["$added_by", "Anonymous"] },
source: { $ifNull: ["$source", "youtube"] },
added_by: {
$ifNull: ["$added_by", "Anonymous"]
},
source: {
$ifNull: ["$source", "youtube"]
},
thumbnail: {
$ifNull: [
"$thumbnail",
@@ -40,7 +56,9 @@ var project_object = {
}
]
},
tags: { $ifNull: ["$tags", []] }
tags: {
$ifNull: ["$tags", []]
}
};
var toShowChannel = {
@@ -62,4 +80,4 @@ var toShowChannel = {
module.exports.project_object = project_object;
module.exports.toShowConfig = toShowConfig;
module.exports.toShowChannel = toShowChannel;
module.exports.toShowChannel = toShowChannel;