From 75d90daeb04032961f096b53843f0d8b16b07ac6 Mon Sep 17 00:00:00 2001 From: Marcos Carlomagno Date: Mon, 12 Sep 2022 09:08:59 -0300 Subject: [PATCH] fix grammar for time-based decisions --- docs/rules.md | 2 +- docs/rules/security/not-rely-on-time.md | 2 +- lib/rules/security/not-rely-on-time.js | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/rules.md b/docs/rules.md index 7140fb64..188fdc37 100644 --- a/docs/rules.md +++ b/docs/rules.md @@ -64,7 +64,7 @@ title: "Rule Index of Solhint" | [no-complex-fallback](./rules/security/no-complex-fallback.md) | Fallback function must be simple. | ✔️ | | [no-inline-assembly](./rules/security/no-inline-assembly.md) | Avoid to use inline assembly. It is acceptable only in rare cases. | ✔️ | | [not-rely-on-block-hash](./rules/security/not-rely-on-block-hash.md) | Do not rely on "block.blockhash". Miners can influence its value. | ✔️ | -| [not-rely-on-time](./rules/security/not-rely-on-time.md) | Avoid to make time-based decisions in your business logic. | ✔️ | +| [not-rely-on-time](./rules/security/not-rely-on-time.md) | Avoid making time-based decisions in your business logic. | ✔️ | | [reentrancy](./rules/security/reentrancy.md) | Possible reentrancy vulnerabilities. Avoid state changes after transfer. | ✔️ | | [state-visibility](./rules/security/state-visibility.md) | Explicitly mark visibility of state. | ✔️ | diff --git a/docs/rules/security/not-rely-on-time.md b/docs/rules/security/not-rely-on-time.md index 3d0838d1..f9998d73 100644 --- a/docs/rules/security/not-rely-on-time.md +++ b/docs/rules/security/not-rely-on-time.md @@ -12,7 +12,7 @@ title: "not-rely-on-time | Solhint" ## Description -Avoid to make time-based decisions in your business logic. +Avoid making time-based decisions in your business logic. ## Options This rule accepts a string option of rule severity. Must be one of "error", "warn", "off". Default to warn. diff --git a/lib/rules/security/not-rely-on-time.js b/lib/rules/security/not-rely-on-time.js index e0570cec..961f7c3f 100644 --- a/lib/rules/security/not-rely-on-time.js +++ b/lib/rules/security/not-rely-on-time.js @@ -5,7 +5,7 @@ const meta = { type: 'security', docs: { - description: `Avoid to make time-based decisions in your business logic.`, + description: `Avoid making time-based decisions in your business logic.`, category: 'Security Rules' }, @@ -34,7 +34,7 @@ class NotRelyOnTimeChecker extends BaseChecker { } _warn(node) { - this.warn(node, 'Avoid to make time-based decisions in your business logic') + this.warn(node, 'Avoid making time-based decisions in your business logic') } }