upgrading multiple function to new format