Fixed bid compute_total as suggested by @fbesse.