Radish alpha
r
Radicle web interface
Radicle
Git (anonymous pull)
Log in to clone via SSH
Require `let` or `const` instead of var
Rūdolfs Ošiņš committed 3 years ago
commit 795d6c43f8bb600d895c638969f41a2dbd16aa2c
parent 853ed5c053ef12ab8c634658dab40d2928c9c882
2 files changed +5 -2
modified .eslintrc.json
@@ -106,7 +106,10 @@
    "prefer-const": "error",
    // Disallow modifying variables that are declared using const.
    // https://eslint.org/docs/rules/no-const-assign
-
    "no-const-assign": "error"
+
    "no-const-assign": "error",
+
    // Require let or const instead of var.
+
    // https://eslint.org/docs/rules/no-var
+
    "no-var": "error"
  },
  "settings": {
    "svelte3/typescript": true
modified src/polyfills/typedarray-to-buffer.js
@@ -7,7 +7,7 @@ import { Buffer } from 'buffer/';

export default function typedarrayToBuffer(arr) {
  if (isTypedArray.strict(arr)) {
-
    var buf = Buffer.from(arr.buffer);
+
    let buf = Buffer.from(arr.buffer);
    if (arr.byteLength !== arr.buffer.byteLength) {
      buf = buf.slice(arr.byteOffset, arr.byteOffset + arr.byteLength);
    }