changed some function names to match their task