Removed services and created a directive