1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-12-02 22:49:09 +02:00

Chore: Apply eslint rules

This commit is contained in:
Laurent Cozic
2019-09-19 22:51:18 +01:00
parent ab29d7e872
commit e648392330
185 changed files with 1196 additions and 1196 deletions

View File

@@ -38,7 +38,7 @@ TemplateUtils.loadTemplates = async function(filePath) {
files = await shim.fsDriver().readDirStats(filePath);
} catch (error) {
let msg = error.message ? error.message : '';
msg = 'Could not read template names from ' + filePath + '\n' + msg;
msg = `Could not read template names from ${filePath}\n${msg}`;
error.message = msg;
throw error;
}
@@ -50,11 +50,11 @@ TemplateUtils.loadTemplates = async function(filePath) {
files.forEach(async file => {
if (file.path.endsWith('.md')) {
try {
let fileString = await shim.fsDriver().readFile(filePath + '/' + file.path, 'utf-8');
let fileString = await shim.fsDriver().readFile(`${filePath}/${file.path}`, 'utf-8');
templates.push({ label: file.path, value: fileString });
} catch (error) {
let msg = error.message ? error.message : '';
msg = 'Could not load template ' + file.path + '\n' + msg;
msg = `Could not load template ${file.path}\n${msg}`;
error.message = msg;
throw error;
}