Skip to content

Commit

Permalink
Resolved merge conflicts with labgen
Browse files Browse the repository at this point in the history
  • Loading branch information
shreyash-x committed May 11, 2023
2 parents 828fe1c + 92d37a1 commit 9fb6488
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ exprepos
plugins/
dist/
*.log
.npmrc
.npmrc
4 changes: 2 additions & 2 deletions assets/js/event-handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ document.getElementById('bug-report').addEventListener('vl-bug-report', (e)=>{
icon: 'success',
iconColor: "white",
background:"#a5dc86",
title: 'Bug Reported Succesfully',
title: 'Bug Reported Successfully',
})
}else{
Toast.fire({
Expand All @@ -38,4 +38,4 @@ document.getElementById('bug-report').addEventListener('vl-bug-report', (e)=>{
title: 'Bug Report Failed, Please Try Again',
})
}
})
})
10 changes: 7 additions & 3 deletions logger.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ var PROJECT_ROOT = __dirname
const { format } = winston;
const { combine, timestamp, printf, colorize } = format;

const myFormat = printf(({ level, message, timestamp }) => {
const vlabsDefaultFormat = printf(({ level, message, timestamp }) => {
return `${timestamp} ${level}: ${message}`;
});

const log = new winston.createLogger({
level: "debug",
format: combine(
timestamp(),
myFormat
vlabsDefaultFormat
),
transports: [
new winston.transports.File({ filename: path.resolve(PROJECT_ROOT,"build-error.log"), level: "error", handleExceptions: true }),
Expand All @@ -31,7 +31,11 @@ log.stream = {
// code and still possible to replace winston in the future.

module.exports.addDebug = function () {
log.add(new winston.transports.Console({level: "debug",format: combine(colorize({all: true}),timestamp(),myFormat), handleExceptions: true}))
log.add(new winston.transports.Console({level: "debug",format: combine(colorize({all: true}),timestamp(),vlabsDefaultFormat), handleExceptions: true}))
}

module.exports.addInfo = function () {
log.add(new winston.transports.Console({level: "info",format: combine(colorize({all: true}),timestamp(),vlabsDefaultFormat), handleExceptions: true}))
}

module.exports.addInfo = function () {
Expand Down
2 changes: 1 addition & 1 deletion main.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ function getAssessmentPath(src,units){
let paths = getAssessmentPath(nextSrc,unit.units);
assessmentPath.push(...paths);
}
if(unit["content-type"] === "assesment" || unit["content-type"] === "assessment"){
if(unit["content-type"] === ContentTypes.ASSESMENT || unit["content-type"] === ContentTypes.ASSESSMENT){
const quiz = path.resolve(src, unit.source);
assessmentPath.push(quiz);
}
Expand Down

0 comments on commit 9fb6488

Please sign in to comment.