updates diagram