updated views and did refactaring some methods