Skip to content

Commit

Permalink
fix ember 4.6
Browse files Browse the repository at this point in the history
  • Loading branch information
runspired committed Jul 25, 2022
1 parent 088d1d6 commit 4a66481
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,6 @@ module('async belongs-to rendering tests', function (hooks) {

let parent = await sedona.parent;
await parent.destroyRecord();
// TODO for some reason parent isn't notified via the destroy above :thinking_face:
let newParent = await sedona.parent;

assert.strictEqual(newParent, null, 'We no longer have a parent');
Expand Down
4 changes: 2 additions & 2 deletions packages/model/addon/-private/system/promise-many-array.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import ArrayMixin from '@ember/array';
import ArrayMixin, { NativeArray } from '@ember/array';
import type ArrayProxy from '@ember/array/proxy';
import { assert } from '@ember/debug';
import { dependentKeyCompat } from '@ember/object/compat';
Expand Down Expand Up @@ -55,7 +55,7 @@ export default class PromiseManyArray {

const meta = Ember.meta(this);
meta.hasMixin = (mixin: Object) => {
if (mixin === ArrayMixin) {
if (mixin === NativeArray || mixin === ArrayMixin) {
return true;
}
return false;
Expand Down
2 changes: 2 additions & 0 deletions packages/store/types/@ember/array/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,8 @@ interface Array<T> extends Enumerable<T> {
declare const Array: Mixin<Array<unknown>>;
export default Array;

export const NativeArray;

/**
* Creates an `Ember.NativeArray` from an Array like object.
* Does not modify the original object's contents. Ember.A is not needed if
Expand Down

0 comments on commit 4a66481

Please sign in to comment.