fixed reduce error