Divsion by zero when using drush search-api-status on empty indexes.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jsacksick’s picture

Corrected by adding a condition on the $status['total'].

jsacksick’s picture

Status: Active » Needs review
drunken monkey’s picture

Patch makes sense, thanks! However, shouldn't we just print "100%" instead of "0"? Or at least "-" to (hopefully) more clearly indicate that this column has no significance for the index in question?

jsacksick’s picture

I think we should print a "-" instead, it would be better. It's up to you to choose between 100% and "-" :)

drunken monkey’s picture

Status: Needs review » Fixed

OK, then let's stick with "-". Committed, thanks!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.