REFACTORING: Extracted getHandlerId_ method and refactored some variable names for better readability