Skip to content

Commit eb581ca

Browse files
fixes some node issues
1 parent 14888a4 commit eb581ca

File tree

5 files changed

+9
-33
lines changed

5 files changed

+9
-33
lines changed

ui/packages/consul-ui/app/components/data-sink/index.js

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,10 @@ export default Component.extend({
2121

2222
state: computed('instance', 'instance.{dirtyType,isSaving}', {
2323
get() {
24-
if (this._state !== undefined) {
25-
return this._state;
26-
}
27-
2824
let id;
2925
const isSaving = get(this, 'instance.isSaving');
3026
const dirtyType = get(this, 'instance.dirtyType');
27+
3128
if (typeof isSaving === 'undefined' && typeof dirtyType === 'undefined') {
3229
id = 'idle';
3330
} else {
@@ -45,18 +42,14 @@ export default Component.extend({
4542
}
4643
id = `active.${id}`;
4744
}
48-
49-
const stateObj = {
45+
46+
return {
5047
matches: (name) => id.indexOf(name) !== -1,
5148
};
52-
53-
this._state = stateObj; // optional cache
54-
return stateObj;
5549
},
5650

5751
set(_key, value) {
58-
this._state = value;
59-
return this._state;
52+
return value;
6053
},
6154
}),
6255

ui/packages/consul-ui/app/components/list-collection/index.js

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -50,26 +50,17 @@ export default Component.extend(Slotted, {
5050

5151
style: computed('height', {
5252
get() {
53-
if (this._style !== undefined) {
54-
return this._style;
55-
}
56-
57-
let styleValue;
5853
if (this.scroll !== 'virtual') {
59-
styleValue = {};
54+
return {};
6055
} else {
61-
styleValue = {
56+
return {
6257
height: this.height,
6358
};
6459
}
65-
66-
this._style = styleValue; // optional caching
67-
return styleValue;
6860
},
6961

7062
set(_key, value) {
71-
this._style = value;
72-
return this._style;
63+
return value;
7364
},
7465
}),
7566

ui/packages/consul-ui/app/components/tabular-collection/index.js

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,6 @@ export default CollectionComponent.extend(Slotted, {
4242

4343
style: computed('rowHeight', '_items', 'maxRows', 'maxHeight', {
4444
get() {
45-
if (this._style !== undefined) {
46-
return this._style;
47-
}
48-
4945
const maxRows = this.rows;
5046
let height = this.maxHeight;
5147

@@ -55,13 +51,11 @@ export default CollectionComponent.extend(Slotted, {
5551
height = this.rowHeight * rows + 29;
5652
}
5753

58-
this._style = { height }; // optional caching
59-
return this._style;
54+
return { height };
6055
},
6156

6257
set(_key, value) {
63-
this._style = value;
64-
return this._style;
58+
return value;
6559
},
6660
}),
6761

ui/packages/consul-ui/app/models/intention-permission-http-header.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,5 @@ export default class IntentionPermission extends Fragment {
4444
set HeaderType(value) {
4545
// Store manual override
4646
this._headerTypeManual = value;
47-
return value;
4847
}
4948
}

ui/packages/consul-ui/app/models/intention-permission-http.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,5 @@ export default class IntentionPermissionHttp extends Fragment {
4141
set PathType(value) {
4242
// Store manual override
4343
this._pathTypeManual = value;
44-
return value;
4544
}
4645
}

0 commit comments

Comments
 (0)