Change function name to formatLog from formatMessage
Change robot logic