changed minor functions