Skip to content

Commit

Permalink
Fix: when no value is provided to bindings
Browse files Browse the repository at this point in the history
  • Loading branch information
dannyrb committed May 27, 2018
1 parent a451e24 commit e2c3160
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ const restoreCallbackFn = function(value) {};
export default {
// This occurs once the directive is attached to the element.
bind: function(el, binding, vnode) {
binding = binding || {}

const cacheKey = binding.value.key || binding.value;
const restoreTarget = binding.value.restoreTarget || "form";
const successHandler = binding.value.successHandler || successHandlerFn;
Expand Down

0 comments on commit e2c3160

Please sign in to comment.