Skip to content

Commit

Permalink
LDBR 2.3: Внести исправления после ревью кода. (#16)
Browse files Browse the repository at this point in the history
  • Loading branch information
GeorgiyX authored Oct 15, 2021
1 parent 86772b9 commit c23bb94
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"plugins": ["unused-imports"],
"env": {
"browser": true,
"es2021": true
Expand All @@ -20,6 +21,7 @@
"linebreak-style": "off",
"no-var": "error",
"no-redeclare": "error",
"unused-imports/no-unused-imports": "error",
"no-unused-vars": "warn",
"max-len": ["error", { "code": 105 }],
"no-irregular-whitespace": "off"
Expand Down
15 changes: 15 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
"body-parser": "^1.18.3",
"eslint": "^7.32.0",
"eslint-config-google": "^0.14.0",
"eslint-plugin-unused-imports": "^1.1.5",
"express": "^4.17.1",
"handlebars": "^4.7.7",
"morgan": "^1.9.1"
Expand Down
2 changes: 1 addition & 1 deletion src/utils/Router/Router.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class Router {
start() {
this._root.addEventListener('click', (event) => {
const link = event.target.closest('a');
if (link instanceof HTMLAnchorElement) {
if (link) {
event.preventDefault();
this.go(link.pathname + link.search);
}
Expand Down

0 comments on commit c23bb94

Please sign in to comment.