minor changes, added readability