Skip to content

Commit

Permalink
remove uneeded variable
Browse files Browse the repository at this point in the history
  • Loading branch information
anjmao committed Feb 2, 2018
1 parent 1aee061 commit 579ca6d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/ng-select/ng-select.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@ export class NgSelectComponent implements OnInit, OnDestroy, OnChanges, AfterVie
filterValue: string = null;

private _ngModel: any = null;
private _simple = false;
private _defaultLabel = 'label';
private _defaultValue = 'value';
private _typeaheadLoading = false;
Expand Down Expand Up @@ -411,8 +410,8 @@ export class NgSelectComponent implements OnInit, OnDestroy, OnChanges, AfterVie
private _setItems(items: any[]) {
const firstItem = items[0];
this.bindLabel = this.bindLabel || this._defaultLabel;
this._simple = firstItem && !(firstItem instanceof Object);
this.itemsList.setItems(items, this._simple);
const simple = firstItem && !(firstItem instanceof Object);
this.itemsList.setItems(items, simple);
if (this._isDefined(this._ngModel) && items.length > 0) {
this.itemsList.clearSelected();
this._selectWriteValue(this._ngModel);
Expand Down

0 comments on commit 579ca6d

Please sign in to comment.