fixes for nitmetrics

Remove some crashes in borderline usages