added more comments
fixed merge conflict