Handle the undefined TotalTicks case
This commit is contained in:
parent
44acb58f8c
commit
5f73c5d392
|
@ -45,7 +45,7 @@ export default Model.extend({
|
|||
|
||||
memoryUsed: computed.readOnly('stats.ResourceUsage.MemoryStats.RSS'),
|
||||
cpuUsed: computed('stats.ResourceUsage.CpuStats.TotalTicks', function() {
|
||||
return Math.floor(this.get('stats.ResourceUsage.CpuStats.TotalTicks'));
|
||||
return Math.floor(this.get('stats.ResourceUsage.CpuStats.TotalTicks') || 0);
|
||||
}),
|
||||
|
||||
percentMemory: computed('taskGroup.reservedMemory', 'memoryUsed', function() {
|
||||
|
|
Loading…
Reference in a new issue