Skip to content

Commit

Permalink
fix bug target undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
adrienpoly committed Jan 31, 2018
1 parent 97e50dd commit 0e0127d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@
/public/packs-test
/node_modules
/public/assets
/loadtest
2 changes: 1 addition & 1 deletion app/javascript/controllers/editable_controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export default class extends Controller {
submitOnBlur(event) {
const form = event.target.closest("form");
Rails.fire(form, "submit");
target.closest("li").classList.remove("editing");
event.target.closest("li").classList.remove("editing");
this.targets.find("input-form").style.display = "none";
}

Expand Down

0 comments on commit 0e0127d

Please sign in to comment.