can pass objects to log function