refactor code

a little bit of cleaning up my code