some refacotring