Refactored angular 2