Define function properly.