[fix] protect against division by 0