Fixed a minor metrics bug causing ever-increasing memory and CPU usage for graphs

Signed-off-by: bergerkiller <bergerkiller@gmail.com>