Skip to content

Commit

Permalink
fix bug that was causing sme careportal treatments to not show a dot
Browse files Browse the repository at this point in the history
  • Loading branch information
jasoncalabrese committed Apr 27, 2016
1 parent 351f3d7 commit c17b07a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/client/renderer.js
Expand Up @@ -197,7 +197,7 @@ function init (client, d3) {
var treatCircles = chart().focus.selectAll('treatment-dot').data(client.ddata.treatments.filter(function(treatment) {

var notCarbsOrInsulin = !treatment.carbs && !treatment.insulin;
var notTempOrProfile = treatment.eventType !== 'Temp Basal' && treatment.eventType !== 'Profile Switch';
var notTempOrProfile = ! _.includes(['Temp Basal', 'Profile Switch', 'Combo Bolus', 'Temporary Target'], treatment.eventType);

var notes = treatment.notes || '';
var enteredBy = treatment.enteredBy || '';
Expand All @@ -206,7 +206,7 @@ function init (client, d3) {
return notes.indexOf(spam) === 0;
}));

return notCarbsOrInsulin && isNaN(treatment.duration) && notTempOrProfile && notOpenAPSSpam;
return notCarbsOrInsulin && !treatment.duration && notTempOrProfile && notOpenAPSSpam;
}));

function prepareTreatCircles(sel) {
Expand Down

0 comments on commit c17b07a

Please sign in to comment.