added comments in registerHandlers fn