Skip to content

Commit

Permalink
[AAE-22900] PR comments update - only checking for falsy sortingMode
Browse files Browse the repository at this point in the history
  • Loading branch information
amolodyh-hyland committed Nov 22, 2024
1 parent 4e3e867 commit 9361b61
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/core/src/lib/datatable/data/object-datatable-adapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,10 @@ export class ObjectDataTableAdapter implements DataTableAdapter {
constructor(data: any[] = [], schema: DataColumn[] = [], sortingMode: SortingMode = 'client') {
this._rows = [];
this._columns = [];
this._sortingMode = sortingMode?.toString().toLowerCase() === 'server' ? 'server' : 'client';

if (!sortingMode) {
sortingMode = 'client';
}

if (data && data.length > 0) {
this._rows = data.map((item) => new ObjectDataRow(item));
Expand Down

0 comments on commit 9361b61

Please sign in to comment.