Implemented the handle functions