Skip to content

Commit 0c52260

Browse files
committed
Made eslint changes
1 parent 5327a0a commit 0c52260

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

models/module.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
import connector from '#models/databaseUtil';
2-
import { logger } from '#util';
1+
import connector from "#models/databaseUtil";
32

4-
connector.set('debug', true);
3+
connector.set("debug", true);
54
const moduleSchema = {
65
modNo: { type: Number, required: true },
76
moduleName: { type: String, required: true },
@@ -11,7 +10,7 @@ const moduleSchema = {
1110
cognitiveLevels: [{ type: String, required: true }],
1211
};
1312

14-
const moduleModel = new connector.model('Module', moduleSchema);
13+
const moduleModel = new connector.model("Module", moduleSchema);
1514

1615
async function remove(filter) {
1716
const res = await moduleModel.findOneAndDelete(filter);
@@ -24,7 +23,7 @@ async function create(
2423
moduleOutcome,
2524
moduleContents,
2625
hrsPerModule,
27-
cognitiveLevels
26+
cognitiveLevels,
2827
) {
2928
const module = new moduleModel({
3029
modNo,
@@ -51,11 +50,13 @@ async function update(filter, updateObject) {
5150
}
5251

5352
async function test() {
54-
await create(1, 'Maths', 'abc', 'xyz', 5, 'abc');
53+
await create(1, "Maths", "abc", "xyz", 5, "abc");
5554
const reading = await read({});
5655
console.log(reading);
5756
}
5857

58+
test();
59+
5960
export default {
6061
create,
6162
read,

0 commit comments

Comments
 (0)