Caleb Porzio il y a 3 ans
Parent
commit
f5d2857a88
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 2 2
      packages/alpinejs/src/interceptor.js

+ 2 - 2
packages/alpinejs/src/interceptor.js

@@ -6,8 +6,8 @@ export function initInterceptors(data) {
 
     let recurse = (obj, basePath = '') => {
         Object.entries(Object.getOwnPropertyDescriptors(obj)).forEach(([key, { value, enumerable }]) => {
-            if (enumerable === false) return
-            if (value === undefined) return
+            // Skip getters.
+            if (enumerable === false || value === undefined) return
 
             let path = basePath === '' ? key : `${basePath}.${key}`