Fix for #204 and removed redundant commented code