fix an order-of-operations screwup