Repository: ember-cli/eslint-plugin-ember (js)

Issue:
no-actions-hash fails on class extensions that contain `...`
Error thrown: `Cannot read property 'name' of undefined` 

How to trigger: 
```
Service.extend({
   ...foo,
})
```

Anything with the spread operator inside a class extension causes a error to be thrown  

Pull request description:
Fix crash with spread syntax in `no-actions-hash` rule
Fixes #921.

Patch:
diff --git a/lib/utils/ember.js b/lib/utils/ember.js
index 2bb87f4b..7f973f64 100644
--- a/lib/utils/ember.js
+++ b/lib/utils/ember.js
@@ -406,7 +406,11 @@ function isRouteLifecycleHook(property) {
 }
 
 function isActionsProp(property) {
-  return property.key.name === 'actions' && types.isObjectExpression(property.value);
+  return (
+    types.isIdentifier(property.key) &&
+    property.key.name === 'actions' &&
+    types.isObjectExpression(property.value)
+  );
 }
 
 function isComponentLifecycleHookName(name) {


Test patch:
diff --git a/tests/lib/rules/no-actions-hash.js b/tests/lib/rules/no-actions-hash.js
index a83b70c5..008acaed 100644
--- a/tests/lib/rules/no-actions-hash.js
+++ b/tests/lib/rules/no-actions-hash.js
@@ -64,6 +64,11 @@ ruleTester.run('no-actions-hash', rule, {
         },
       });
     `,
+
+    // Spread syntax
+    'Route.extend({ ...foo });',
+    'Route.extend(Evented, { ...foo });',
+    'Route.extend(...foo);',
   ],
 
   invalid: [