From cfd7d14d3fdd69873b7bd507fb59cd7016ea96fa Mon Sep 17 00:00:00 2001 From: Dario Merz Date: Thu, 28 May 2020 11:45:41 +0200 Subject: [PATCH] fix: check for undefined and null the GraphQL API returns `null` in `_editable` if content-version is set to "published", therefore the check fails. --- storyblok-vue.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/storyblok-vue.js b/storyblok-vue.js index cac3635c..f66f1caa 100644 --- a/storyblok-vue.js +++ b/storyblok-vue.js @@ -12,7 +12,7 @@ Vue.directive('editable', { bind: function(el, binding) { - if (typeof binding.value._editable === 'undefined') { + if (typeof binding.value._editable === 'undefined' || binding.value._editable === null) { return }