diff options
Diffstat (limited to 'src/models/Service.js')
-rw-r--r-- | src/models/Service.js | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/models/Service.js b/src/models/Service.js index 0b19440e7..652d2594c 100644 --- a/src/models/Service.js +++ b/src/models/Service.js | |||
@@ -24,7 +24,7 @@ export default class Service { | |||
24 | @observable isNotificationEnabled = true; | 24 | @observable isNotificationEnabled = true; |
25 | @observable isBadgeEnabled = true; | 25 | @observable isBadgeEnabled = true; |
26 | @observable isIndirectMessageBadgeEnabled = true; | 26 | @observable isIndirectMessageBadgeEnabled = true; |
27 | @observable customIconUrl = ''; | 27 | @observable iconUrl = ''; |
28 | @observable hasCrashed = false; | 28 | @observable hasCrashed = false; |
29 | 29 | ||
30 | constructor(data, recipe) { | 30 | constructor(data, recipe) { |
@@ -42,7 +42,8 @@ export default class Service { | |||
42 | this.name = data.name || this.name; | 42 | this.name = data.name || this.name; |
43 | this.team = data.team || this.team; | 43 | this.team = data.team || this.team; |
44 | this.customUrl = data.customUrl || this.customUrl; | 44 | this.customUrl = data.customUrl || this.customUrl; |
45 | this.customIconUrl = data.customIconUrl || this.customIconUrl; | 45 | // this.customIconUrl = data.customIconUrl || this.customIconUrl; |
46 | this.iconUrl = data.iconUrl || this.iconUrl; | ||
46 | 47 | ||
47 | this.order = data.order !== undefined | 48 | this.order = data.order !== undefined |
48 | ? data.order : this.order; | 49 | ? data.order : this.order; |
@@ -97,15 +98,15 @@ export default class Service { | |||
97 | } | 98 | } |
98 | 99 | ||
99 | @computed get icon() { | 100 | @computed get icon() { |
100 | if (this.hasCustomIcon) { | 101 | if (this.iconUrl) { |
101 | return this.customIconUrl; | 102 | return this.iconUrl; |
102 | } | 103 | } |
103 | 104 | ||
104 | return path.join(this.recipe.path, 'icon.svg'); | 105 | return path.join(this.recipe.path, 'icon.svg'); |
105 | } | 106 | } |
106 | 107 | ||
107 | @computed get hasCustomIcon() { | 108 | @computed get hasCustomIcon() { |
108 | return (this.customIconUrl !== ''); | 109 | return Boolean(this.iconUrl); |
109 | } | 110 | } |
110 | 111 | ||
111 | @computed get iconPNG() { | 112 | @computed get iconPNG() { |