Skip to content

Commit 1d8aaa9

Browse files
committed
Fix incomplete sentence.
Fix run-on sentence. Fix comma splice. Remove repetitive clause.
1 parent a390708 commit 1d8aaa9

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

doc/en/core/eval.md

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ The `eval` function will execute a string of JavaScript code in the local scope.
1111
test(); // 3
1212
foo; // 1
1313

14-
But `eval` only executes in local scope when it is being called **directly** *and*
15-
the name of the called function is actually `eval`.
14+
However, `eval` only executes in the local scope when it is being called
15+
**directly** *and* when the name of the called function is actually `eval`.
1616

1717
var foo = 1;
1818
function test() {
@@ -35,14 +35,13 @@ in the global scope since `eval` is not being called directly in that case.
3535

3636
### Security Issues
3737

38-
`eval` also is a security problem as it executes **any** code given to it,
38+
`eval` also is a security problem. Because it executes **any** code given to it,
3939
it should **never** be used with strings of unknown or untrusted origins.
4040

4141
### In Conclusion
4242

43-
`eval` should never be used, any code that makes use of it is to be questioned in
43+
`eval` should never be used. Any code that makes use of it is to be questioned in
4444
its workings, performance and security. In case something requires `eval` in
45-
order to work, its design is to be questioned and should **not** be used in the
46-
first place, a *better design* should be used, that does not require the use of
47-
`eval`.
45+
order to work, it should **not** be used in the first place.
46+
A *better design* should be used, that does not require the use of `eval`.
4847

0 commit comments

Comments
 (0)