bug fix: max reduction