functions.h cleanup