modifying functions to stop compiler warnings