Refactoring and Added ability to hide Share