Fix divison by 0 issue in debug plugin

If you send an empty DB query (thus strlen($query) = 0) you get a division by 0.