commented irrelevant code
refactored