fixed divide by zero in AMPathPreview