small refaactor