diff --git a/.eslintrc.js b/.eslintrc.js index 569d6056b..bcf86e3b0 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -59,6 +59,7 @@ module.exports = { 'no-plusplus': ['error', { 'allowForLoopAfterthoughts': true }], 'no-process-exit': 'error', 'no-prototype-builtins': 'error', + 'no-template-curly-in-string': 'error', 'no-useless-catch': 'error', 'no-useless-concat': 'error', 'prefer-rest-params': 'error', diff --git a/app/scripts/lib/decrypt-message-manager.js b/app/scripts/lib/decrypt-message-manager.js index 89aa259b6..2a53c9fa2 100644 --- a/app/scripts/lib/decrypt-message-manager.js +++ b/app/scripts/lib/decrypt-message-manager.js @@ -253,7 +253,7 @@ export default class DecryptMessageManager extends EventEmitter { _setMsgStatus (msgId, status) { const msg = this.getMsg(msgId) if (!msg) { - throw new Error('DecryptMessageManager - Message not found for id: "${msgId}".') + throw new Error(`DecryptMessageManager - Message not found for id: "${msgId}".`) } msg.status = status this._updateMsg(msg) diff --git a/app/scripts/lib/encryption-public-key-manager.js b/app/scripts/lib/encryption-public-key-manager.js index b927b161a..6ca78fdcf 100644 --- a/app/scripts/lib/encryption-public-key-manager.js +++ b/app/scripts/lib/encryption-public-key-manager.js @@ -247,7 +247,7 @@ export default class EncryptionPublicKeyManager extends EventEmitter { _setMsgStatus (msgId, status) { const msg = this.getMsg(msgId) if (!msg) { - throw new Error('EncryptionPublicKeyManager - Message not found for id: "${msgId}".') + throw new Error(`EncryptionPublicKeyManager - Message not found for id: "${msgId}".`) } msg.status = status this._updateMsg(msg) diff --git a/app/scripts/lib/message-manager.js b/app/scripts/lib/message-manager.js index b2de1eeab..b06246852 100644 --- a/app/scripts/lib/message-manager.js +++ b/app/scripts/lib/message-manager.js @@ -225,7 +225,7 @@ export default class MessageManager extends EventEmitter { _setMsgStatus (msgId, status) { const msg = this.getMsg(msgId) if (!msg) { - throw new Error('MessageManager - Message not found for id: "${msgId}".') + throw new Error(`MessageManager - Message not found for id: "${msgId}".`) } msg.status = status this._updateMsg(msg) diff --git a/app/scripts/lib/typed-message-manager.js b/app/scripts/lib/typed-message-manager.js index 8d7bc6ad5..4bab84d3e 100644 --- a/app/scripts/lib/typed-message-manager.js +++ b/app/scripts/lib/typed-message-manager.js @@ -292,7 +292,7 @@ export default class TypedMessageManager extends EventEmitter { _setMsgStatus (msgId, status) { const msg = this.getMsg(msgId) if (!msg) { - throw new Error('TypedMessageManager - Message not found for id: "${msgId}".') + throw new Error(`TypedMessageManager - Message not found for id: "${msgId}".`) } msg.status = status this._updateMsg(msg)