URL correction in functions