replace all functions after applying migrations
remove function definitions from migrations