added a constructor for the handler