little refactorign