cleaned up some unused code and added form support for friends metadata