Skip to content

Commit e7c66bb

Browse files
committed
Fix linting error (#775)
1 parent c072864 commit e7c66bb

File tree

2 files changed

+11
-13
lines changed

2 files changed

+11
-13
lines changed

app/components/api-index-filter.js

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* eslint-disable ember/no-computed-properties-in-native-classes, ember/classic-decorator-no-classic-methods */
21
import { classNames } from '@ember-decorators/component';
32
import { computed } from '@ember/object';
43
import Component from '@ember/component';
@@ -26,19 +25,19 @@ export default class ApiIndexFilter extends Component {
2625

2726
filterItems(itemType) {
2827
let items =
29-
this.get(`model.${itemType}`) === undefined
28+
this.model[`${itemType}`] === undefined
3029
? []
31-
: this.get(`model.${itemType}`);
32-
if (!this.get('filterData.showInherited')) {
30+
: this.model[`${itemType}`];
31+
if (!this.filterData.showInherited) {
3332
items = items.filter((item) => item.inherited !== true);
3433
}
35-
if (!this.get('filterData.showProtected')) {
34+
if (!this.filterData.showProtected) {
3635
items = items.filter((item) => item.access !== 'protected');
3736
}
38-
if (!this.get('filterData.showPrivate')) {
37+
if (!this.filterData.showPrivate) {
3938
items = items.filter((item) => item.access !== 'private');
4039
}
41-
if (!this.get('filterData.showDeprecated')) {
40+
if (!this.filterData.showDeprecated) {
4241
items = items.filter((item) => item.deprecated !== true);
4342
}
4443

@@ -91,8 +90,8 @@ export default class ApiIndexFilter extends Component {
9190
* @method findMostLocal
9291
*/
9392
findMostLocal(currentItem, nextItem) {
94-
let currentScope = this.get('model.file');
95-
let parentClassScope = this.get('model.parentClass.file');
93+
let currentScope = this.model.file;
94+
let parentClassScope = this.model.parentClass.file;
9695
if (currentScope === currentItem.file) {
9796
// if the item belongs to the class, keep it
9897
return currentItem;

app/components/api-index.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* eslint-disable ember/no-computed-properties-in-native-classes, ember/classic-decorator-no-classic-methods */
21
import { computed } from '@ember/object';
32
import Component from '@ember/component';
43

@@ -9,21 +8,21 @@ export default class ApiIndex extends Component {
98
{
109
title: 'Methods',
1110
tab: 'methods',
12-
items: this.get('itemData.methods'),
11+
items: this.itemData.methods,
1312
class: 'spec-method-list',
1413
routeSuffix: '.methods.method',
1514
},
1615
{
1716
title: 'Properties',
1817
tab: 'properties',
19-
items: this.get('itemData.properties'),
18+
items: this.itemData.properties,
2019
class: 'spec-property-list',
2120
routeSuffix: '.properties.property',
2221
},
2322
{
2423
title: 'Events',
2524
tab: 'events',
26-
items: this.get('itemData.events'),
25+
items: this.itemData.events,
2726
class: 'spec-event-list',
2827
routeSuffix: '.events.event',
2928
},

0 commit comments

Comments
 (0)