set relay function added