Fixed bugs

Both the activities and metric tabs now work without any exceptions.