Skip to content

Commit

Permalink
no need for a document model
Browse files Browse the repository at this point in the history
  • Loading branch information
AmauryD committed May 30, 2024
1 parent 949a2f1 commit a276c23
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 27 deletions.
21 changes: 0 additions & 21 deletions app/models/document.ts

This file was deleted.

7 changes: 1 addition & 6 deletions app/models/user.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import Model, { attr, hasMany } from '@ember-data/model';
import type DocumentModel from './document';
import Model, { attr } from '@ember-data/model';
import { ResourceType } from '@warp-drive/core-types/symbols';

export default class UserModel extends Model {
Expand All @@ -9,10 +8,6 @@ export default class UserModel extends Model {
@attr('string') declare phone: string;
@attr('string') declare role: string;
@attr('string') declare password: string;
@hasMany<DocumentModel>('document', {
async: false,
inverse: 'user',
}) declare documents: DocumentModel[];

[ResourceType] = 'user' as const;
}

0 comments on commit a276c23

Please sign in to comment.