Skip to content

Commit

Permalink
fix: catch more not a cal fire incident suffixes
Browse files Browse the repository at this point in the history
  • Loading branch information
advayDev1 committed Aug 30, 2019
1 parent 12bd3f5 commit f5f121f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/calfire.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ const processFire = function(e, provenance) {
ret2[nfsaMapping[key]] = ret[key];
}
});
if (ret2.Fire_Name.endsWith(' (Not a CAL FIRE Incident)') || ret2.Fire_Name.endsWith(' [Not a CAL FIRE Incident]')) {
const lfn = ret2.Fire_Name.toLowerCase();
if (lfn.endsWith(' (not a cal fire incident)') || lfn.endsWith(' (not a cal fire incident)')) {
ret2.Fire_Name = ''.substr(0, ret2.Fire_Name.length - ' (Not a CAL FIRE Incident)'.length);
ret2.Notes = '(Not a CAL FIRE Incident)';
}
Expand Down

0 comments on commit f5f121f

Please sign in to comment.