Skip to content

Commit

Permalink
Merge pull request #750 from x-b-e/fix-ember-metal-imports
Browse files Browse the repository at this point in the history
fix: ember metal imports
  • Loading branch information
mansona committed Feb 22, 2024
2 parents 28f2dcb + 4810b8d commit 98c962f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions addon/-private/ember-internals.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import __EMBER_METAL__ from '@ember/-internals/metal/index';
import { isClassicDecorator, descriptorForDecorator, } from '@ember/-internals/metal';

export function getDependentKeys(descriptorOrDecorator) {
if (__EMBER_METAL__ && __EMBER_METAL__.descriptorForDecorator) {
let descriptor = __EMBER_METAL__.descriptorForDecorator(
if (descriptorForDecorator) {
let descriptor = descriptorForDecorator(
descriptorOrDecorator
);
return descriptor._dependentKeys || [descriptor.altKey];
Expand All @@ -12,8 +12,8 @@ export function getDependentKeys(descriptorOrDecorator) {
}

export function isDescriptor(o) {
if (__EMBER_METAL__ && __EMBER_METAL__.isClassicDecorator) {
return __EMBER_METAL__.isClassicDecorator(o);
if (isClassicDecorator) {
return isClassicDecorator(o);
} else {
return (
o && (typeof o === 'object' || typeof o === 'function') && o.isDescriptor
Expand Down

0 comments on commit 98c962f

Please sign in to comment.