Updated shared functions.