fixed metrics bug