Fixed bug which caused repeated minimizations with same chi2r to happen.