Skip to content
This repository has been archived by the owner on Sep 7, 2023. It is now read-only.

Commit

Permalink
🐛 Correctly access subjects relationship
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiasrohmer committed Jul 8, 2021
1 parent ca306b4 commit e084de9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/Helpers/Managers/BaseManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@ export class BaseManager {
this.method = this.ctx.request.method();
}

public query(options: { sort?: string; includes?: string; filter?: string }) {
public query(
options: { sort?: string; includes?: string; filter?: string } = {}
) {
let query = this.ModelClass.query();
if (this.ModelClass.$hasRelation('translations')) {
query = query.preload('translations');
Expand Down

0 comments on commit e084de9

Please sign in to comment.