made code more consistant