Updated Logic. Implemented EditLogic