Refactored StatusCodeHandler to take a string as an input code.