Refactor Request Handler