small refacoring